-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
changefeedccl: only checkpoint leading spans above lead threshold #138790
changefeedccl: only checkpoint leading spans above lead threshold #138790
Conversation
11daf77
to
8644262
Compare
This patch renames `changefeed.frontier_checkpoint_max_bytes` to `changefeed.span_checkpoint.max_bytes` for consistency. Release note: None
8644262
to
d2d3f8f
Compare
This patch renames `changefeed.frontier_checkpoint_frequency` to `changefeed.span_checkpoint.interval` for consistency. Release note: None
d2d3f8f
to
8ec98be
Compare
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.
I haven't looked closely so take this with a grain of salt, but I think this is the kind of change were we would benefit from the "painful elaboration of the obvious" in the commit message so that in a few months anyone partially familiar with changefeeds can understand we expect this change to do.
c7d49f2
to
f07beab
Compare
Thanks for the feedback, added a longer explanation in the commit message. |
…reshold setting This patch renames `changefeed.frontier_highwater_lag_checkpoint_threshold` to `changefeed.span_checkpoint.lead_threshold` for consistency. Release note (ops change): The cluster setting `changefeed.frontier_highwater_lag_checkpoint_threshold` has been renamed to `changefeed.span_checkpoint.lead_threshold`. The old name remains available for backwards-compatibility.
This patch updates the span-level checkpointing code to only checkpoint spans that are above the lead threshold (formerly lag threshold) so that we can at least maintain some minimal level of progress for spans that we go through the effort of checkpointing. Longer explanation: We create span-level checkpoints (at the configured interval) if we are either in a backfill or there's at least one span that is more than the lag/lead threshold ahead of the frontier min ts. Before this change, in the latter case, we would checkpoint all spans that are above the frontier min ts regardless of whether they are at least the lag/lead threshold ahead. This change makes it so that when we are creating a span-level checkpoint due to the lag/lead threshold, we will only include spans that are ahead of the frontier min ts by at least the lag/lead threshold so that we can maintain some minimal level of progress for the spans that we checkpoint. Release note: None
f07beab
to
bdd0cd4
Compare
We discussed this change offline and decided the risks associated with this change aren't worth it given the planned work to improve span-level checkpoints. I pulled the first 3 commits renaming settings into a separate PR (#139064) and I'll close this PR soon. |
See individual commits
Fixes #137857