Skip to content

Check state again after connecting to ensure we don't resurrect a dead session#99

Open
hamzahrmalik wants to merge 1 commit into
apple:mainfrom
hamzahrmalik:fix_shutdown_race
Open

Check state again after connecting to ensure we don't resurrect a dead session#99
hamzahrmalik wants to merge 1 commit into
apple:mainfrom
hamzahrmalik:fix_shutdown_race

Conversation

@hamzahrmalik

Copy link
Copy Markdown
Contributor

currently, if session was shut down during the connect, we unconditionally set it back to state connected again, rather than keeping it disconnected

We should instead check the current state again to make sure we don't resurrect a dead connection and mark it as connected.

Added a test which would've hit the fatalError in CassandraClient/deinit without the changes in this commit

…d session

if session was shut down during the connect, we unconditionally set it back to state connected again, rather than keeping it disconnected
@yifan-c yifan-c added the 🔨 semver/patch No public API change. label Jun 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🔨 semver/patch No public API change.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants