The unit and integration test cases for this were very comprehensive. I added a few more and did some manual validation with a load test. Looks good to merge!
Olivier Michallat
March 9, 2015 at 9:41 AM
The logger should emphasize queries that timed out. Clients needs to pay special attention to them as they mark the node down. See RequestHandler#onTimeout.
Olivier Michallat
March 9, 2015 at 9:21 AM
Yes, this would be a very useful feature. We have a couple of tickets in 2.0.10 that will help log statements better, so I'm tentatively adding this one as well.
It would be great if there was a way to log if a Cassandra query takes longer then a configured length of time.
E.g.
if (timeTakenMs >= slowQueryThresholdMs) { LOGGER.warn("Query took longer than configured threshold. Query: {}, time taken ms: {}, threshold ms: {}", query, timeTakenMs, slowQueryThresholdMs); } else { LOGGER.debug("Query executed. Query: {}, time taken ms: {}", query, timeTakenMs); }
The problem with doing this outside of the driver is that it may include any retries or connections.