management-api-for-apache-cassandra
management-api-for-apache-cassandra copied to clipboard
K8SSAND-153 ⁃ Improve logging around driver connection attempts
When a Management API server instance starts up and starts Cassandra, it tries to establish a Driver CqlSession over the Unix socket that the Management API agent creates on Cassandra startup. Until Cassandra creates this socket however, the server will fail to establish a connection and thus a CqlSession. You will see logs similar to:
WARN [epollEventLoopGroup-81-2] 2021-02-24 13:33:29,403 Loggers.java:39 - [s76] Error connecting to Node(endPoint=/tmp/cassandra.sock, hostId=null, hashCode=5f84d3e5), trying next node (FileNotFoundException: null)
This NullPointerException is misleading and can make you think that there is a problem. It is normal for this to occur while Cassandra is starting, though if it persists for a while, there may indeed be an issue preventing Cassandra from starting (i.e. not enough available memory for the container to start).
It would be better if the logs in this case indicated what is happening (and what might be a problem).
┆Issue is synchronized with this Jira Story by Unito