You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
By the way @kevinkyyro , this won't really help with gocql not reconnecting, it will just stop the panic from happening. I believe your issue with the reconnection is related to gocql-astra adding a single contact point which causes gocql to fail after 1 connection attempt (see: datastax/gocql-astra#24 )
In any case I've opened a PR to fix this deadlock issue: #1767
joao-r-reis
changed the title
Deadlock in refreshDebouncer when reconnection fails
CASSGO-41 Deadlock in refreshDebouncer when reconnection fails
Nov 25, 2024
What version of Cassandra are you using?
astra-classic
What version of Gocql are you using?
v1.6.0
What version of Go are you using?
1.21
What did you do?
Connection errors, I think due to overload, lead to frequent reconnection attempts and failures
What did you expect to see?
Should retry until connection succeeds
What did you see instead?
Deadlock
It looks like a race condition between
(*refreshDebouncer).stop()
and(*refreshDebouncer).flusher()
stop()
acquiresd.mu
and setsd.stopped
to trueflusher()
exits theselect
at the top of the loop and blocks on acquiringd.mu
stop()
releasesd.mu
and tries to write tod.quit
flusher()
acquiresd.mu
and returns becaused.stopped
is truestop()
is deadlocked becaused.quit
is unbuffered and the reader has stoppedThe text was updated successfully, but these errors were encountered: