joao-r-reis commented on code in PR #1755:
URL:
https://github.com/apache/cassandra-gocql-driver/pull/1755#discussion_r2143307261
##########
control.go:
##########
@@ -308,10 +325,16 @@ func (c *controlConn) setupConn(conn *Conn) error {
return err
}
- host = c.session.ring.addOrUpdate(host)
+ var exists bool
+ host, exists = c.session.ring.addOrUpdate(host)
if c.session.cfg.filterHost(host) {
- return fmt.Errorf("host was filtered: %v",
host.ConnectAddress())
+ return fmt.Errorf("host was filtered: %v (%s)",
host.ConnectAddress(), host.HostID())
+ }
+
+ if !exists {
+ c.session.logger.Info("Adding host.",
Review Comment:
I'm going to change this message to better indicate that this is the control
host. I tend to favor Info level for topology changes because they shouldn't
happen that often and I feel like they are important enough that it warrants
the INFO level. Maybe I should add something to distinguish between a host
being added as part of the initialization process and a host being added as
part of a refresh/event post-init?
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]