Skip to content

changefeedccl: apply all checkpoints before flushing#162546

Open
jeffswenson wants to merge 1 commit intocockroachdb:masterfrom
jeffswenson:jeffswenson-changefeed-dedupe-checkpoints
Open

changefeedccl: apply all checkpoints before flushing#162546
jeffswenson wants to merge 1 commit intocockroachdb:masterfrom
jeffswenson:jeffswenson-changefeed-dedupe-checkpoints

Conversation

@jeffswenson
Copy link
Collaborator

Previously, the checkpoint logic lived in side of the per-span loop. This could result in updating a checkpoint O(spans) times when there is a lagging span in the frontier. This has always been slightly sub-optimal, because we may advance the high water mark multiple times while processing spans, but its particularly costly as of 25.4 because we save individual frontier changes.

Release note (performance improvement): improved the performance on changefeed checkpoint when changefeeds are lagging. Informs: #158913

Previously, the checkpoint logic lived in side of the per-span loop.
This could result in updating a checkpoint O(spans) times when there is
a lagging span in the frontier. This has always been slightly
sub-optimal, because we may advance the high water mark multiple times
while processing spans, but its particularly costly as of 25.4 because
we save individual frontier changes.

Release note (performance improvement): improved the performance on
changefeed checkpoint when changefeeds are lagging.
Informs: cockroachdb#158913
@jeffswenson jeffswenson requested a review from a team as a code owner February 5, 2026 16:13
@jeffswenson jeffswenson requested review from andyyang890 and removed request for a team February 5, 2026 16:13
@trunk-io
Copy link
Contributor

trunk-io bot commented Feb 5, 2026

Merging to master in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

@blathers-crl
Copy link

blathers-crl bot commented Feb 5, 2026

It looks like your PR touches production code but doesn't add or edit any test code. Did you consider adding tests to your PR?

🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

@cockroach-teamcity
Copy link
Member

This change is Reviewable

@jeffswenson jeffswenson added backport-26.1.x Flags PRs that need to be backported to 26.1 backport-25.4.x Flags PRs that need to be backported to 25.4 labels Feb 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-25.4.x Flags PRs that need to be backported to 25.4 backport-26.1.x Flags PRs that need to be backported to 26.1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants