File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -85,6 +85,25 @@ usually after each new minor release, to collapse the transport versions
8585for the previous minor release. An example of such an operation can be found
8686[ here] ( https://github.com/elastic/elasticsearch/pull/104937 ) .
8787
88+ #### Tips
89+
90+ - We collapse versions only on the ` main ` branch.
91+ - Use [ TransportVersions.csv] ( ../../server/src/main/resources/org/elasticsearch/TransportVersions.csv ) as your guide.
92+ - For each release version listed in that file with a corresponding ` INITIAL_ELASTICSEARCH_ ` entry corresponding to that version,
93+ - change the prefix to ` V_ `
94+ - replace all intervening entries since the previous patch ` V_ ` entry with the new ` V_ ` entry
95+ - look at all uses of the new ` V_ ` entry and look for dead code that can be deleted
96+
97+ For example, if there's a version ` 1.2.3 ` in the CSV file,
98+ and ` TransportVersions.java ` has an entry called ` INITIAL_ELASTICSEARCH_1_2_3 ` ,
99+ then:
100+ - rename it to ` V_1_2_3 ` ,
101+ - replace any other intervening symbols between ` V_1_2_2 ` and ` V_1_2_3 ` with ` V_1_2_3 ` itself, and
102+ - look through all the uses of the new ` V_1_2_3 ` symbol; if any contain dead code, simplify it.
103+
104+ When in doubt, you can always leave the code as-is.
105+ This is an optional cleanup step that is never required for correctness.
106+
88107### Minimum compatibility versions
89108
90109The transport version used between two nodes is determined by the initial handshake
You can’t perform that action at this time.
0 commit comments