Skip to content

vector-store: stop dropping the CDC driver's supervisor future on shutdown#518

Draft
QuerthDP wants to merge 1 commit into
scylladb:masterfrom
QuerthDP:fix-orphaned-cdc-readers
Draft

vector-store: stop dropping the CDC driver's supervisor future on shutdown#518
QuerthDP wants to merge 1 commit into
scylladb:masterfrom
QuerthDP:fix-orphaned-cdc-readers

Conversation

@QuerthDP

@QuerthDP QuerthDP commented Jul 13, 2026

Copy link
Copy Markdown
Member

spawn_handler_task raced the driver's supervisor future against a shutdown Notify in a tokio::select!. The Notify branch almost always won, dropping the supervisor future before it could propagate the new stop timestamp to its internally spawned per-stream fetch tasks. Those tasks are plain tokio::spawn + JoinHandle with no abort mechanism, so they were orphaned and kept running (and checkpointing) forever.

Fixed by pinning the handler future and looping until it resolves on its own once shutdown is requested, rather than dropping it.

…tdown

`spawn_handler_task` raced the driver's supervisor future against
a shutdown `Notify` in a `tokio::select!`. The Notify branch almost
always won, dropping the supervisor future before it could propagate
the new stop timestamp to its internally spawned per-stream fetch tasks.
Those tasks are plain `tokio::spawn` + `JoinHandle` with no abort mechanism,
so they were orphaned and kept running (and checkpointing) forever.

Fixed by pinning the handler future and looping until it resolves on
its own once shutdown is requested, rather than dropping it.
@QuerthDP QuerthDP changed the title vector-store: stop dropping the CDC driver's supervisor future on sht vector-store: stop dropping the CDC driver's supervisor future on shutdown Jul 13, 2026
@QuerthDP
QuerthDP requested a review from ewienik July 13, 2026 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant