joao-r-reis commented on issue #1873: URL: https://github.com/apache/cassandra-gocql-driver/issues/1873#issuecomment-2778506348
Oh I think the issue is that the [control connection queries system.local and updates that host's entry in the map when it connects/reconnects](https://github.com/apache/cassandra-gocql-driver/blob/c75ff5f282183704b0921610d55ff3f031f45737/control.go#L305-L311)... Other drivers (except java driver 4.x I think) just trigger a full ring refresh when the control connection connects/reconnects and I think we should do this on gocql as well. Basically we can move the `refreshRing` call from `reconnect` to `setupConn` I think. The issue is that `refreshRing` triggers `r.session.startPoolFill(h)` and we only this to be triggered if if it's a reconnection (i.e. `c.session.initialized() == true`). The way this is handled on the C# driver for example is by having event handlers that are only set at the end of the session initialization process so the ring refresh that happens as part of the first control connection setup don't call those event handlers. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org