-
Notifications
You must be signed in to change notification settings - Fork 25.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introduce Local checkpoints #15390
Introduce Local checkpoints #15390
Conversation
|
||
|
||
/** | ||
* an order list of bit arrays representing pending seq nos. The list is "anchored" in {@link #firstSeqNoInProcessSeqNo} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: "an order list" -> "an ordered list"
*/ | ||
final LinkedList<FixedBitSet> processedSeqNo; | ||
final int bitArraysSize; | ||
long firstSeqNoInProcessSeqNo = 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: This name is a mouthful; can it just be firstSeqNoInProcess
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, it's an annoying name. Tweaked.
This is a much simpler implementation than the first. I've minor comments on LocalCheckpointService and the associated tests but otherwise LGTM. |
Thanks @jasontedor . I pushed another commit, addressing all your feedback |
"index.translog.interval", | ||
"index.translog.sync_interval", | ||
"index.shard.inactive_time", | ||
LocalCheckpointService.SETTINGS_BIT_ARRAYS_SIZE, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: The indentation is off on this line.
I have one more small nit, but LGTM. |
pushed to |
This PR introduces the notion of a local checkpoint on the shard level. A local check point is defined as a the highest sequence number for which all previous operations (i.e. with a lower seq#) have been processed.
The current implementation is based on a fixed in memory bit array which is used in a round robin fashion. This introduces a limit to the spread between inflight indexing operation. We are still discussing options to work around this, but I think we should move forward toward a working system and optimize from there (and either remove this limitation or better understand it's implications).
relates to #10708
replaces #15111