forked from elastic/elasticsearch
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Translog.Delete serialization for sequence numbers (elastic#22543)
* Fix Translog.Delete serialization for sequence numbers Translog.Delete used `.writeVLong` instead of `.writeLong` for the sequence number and primary term (and their respective "read" variants). This could lead to issues where a 5.x node sent a translog operation with a negative sequence number (-2 for unassigned seq no) that tripped an assertion serializing a negative number and causing ES to exit. Adds a unit test for serialization and a mixed-cluster REST test, since that was how this was originally caught. * Use more realistic values for random seqNum and primary term * Add comment with TODO for removal in 7.0 * Change comment into an assert
- Loading branch information
Showing
3 changed files
with
87 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters