Skip to content

Close a gap in tracking writer/flusher sync - #10453

Open
pnthao wants to merge 3 commits into
mainfrom
thao/granular_refresh_writer_gap
Open

Close a gap in tracking writer/flusher sync#10453
pnthao wants to merge 3 commits into
mainfrom
thao/granular_refresh_writer_gap

Conversation

@pnthao

@pnthao pnthao commented Aug 13, 2026

Copy link
Copy Markdown
Member

Close a gap in tracking writer/flusher sync

There used to be a small window where a tracking writer (DML)
failed to decrease num_writers on failure exit. This commit fixes
the issue by making sure ts_tenant_tracker_end_batch is called
during transaction abort events.

I will merge into one commit before merging. Separating reproducers from the fix now so it's easier to review.
Disable-check: force-changelog-file

@codecov

codecov Bot commented Aug 13, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 4 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
tsl/src/continuous_aggs/insert.c 71.42% 3 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@pnthao
pnthao force-pushed the thao/granular_refresh_writer_gap branch from ab8e4f1 to 705c642 Compare August 13, 2026 19:31
pnthao added 3 commits August 31, 2026 12:13
Demonstrate that there could be cases when an interrupted tracking
writer (DML) can leave num_writers positive forever, blocking future
flusher (refresh).
There used to be a small window where a tracking writer (DML)
failed to decrease num_writer on failure exit. This commit fixes
the issue by making sure ts_tenant_tracker_end_batch is called
during transaction abort events.
Move the pin release during abort to before the early return block,
and add some asserts to guard against possible changes that could
invalidate current assumptions about where/when a generation gets
pinned/unpinned
@pnthao
pnthao force-pushed the thao/granular_refresh_writer_gap branch from 705c642 to 0fa520f Compare August 31, 2026 19:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant