diff --git a/spectator-ext-jvm/src/main/resources/cassandra.conf b/spectator-ext-jvm/src/main/resources/cassandra.conf index 48b57b880..063c7bd09 100644 --- a/spectator-ext-jvm/src/main/resources/cassandra.conf +++ b/spectator-ext-jvm/src/main/resources/cassandra.conf @@ -459,6 +459,172 @@ netflix.spectator.agent.jmx { ] }, + // + // type=Keyspace + // + { + query = "org.apache.cassandra.metrics:type=Keyspace,keyspace=*,name=*Latency" + measurements = [ + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "count" + }, + { + key = "atlas.dstype" + value = "rate" + } + ] + value = "{OneMinuteRate}" + }, + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "max" + }, + { + key = "atlas.dstype" + value = "gauge" + } + ] + value = "{Max},1e6,:div" + }, + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "totalTime" + }, + { + key = "atlas.dstype" + value = "rate" + } + ] + // 50th percentile is used instead of mean because prior to metrics3 the mean + // is for the life of the timer rather than for the last snapshot of the + // reservoir + value = "{50thPercentile},1e6,:div,{OneMinuteRate},:mul,{Count},{previous:Count},:if-changed" + }, + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "percentile_50" + }, + { + key = "atlas.dstype" + value = "gauge" + } + ] + value = "{50thPercentile},1e6,:div,{Count},{previous:Count},:if-changed" + }, + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "percentile_95" + }, + { + key = "atlas.dstype" + value = "gauge" + } + ] + value = "{95thPercentile},1e6,:div,{Count},{previous:Count},:if-changed" + }, + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "percentile_99" + }, + { + key = "atlas.dstype" + value = "gauge" + } + ] + value = "{99thPercentile},1e6,:div,{Count},{previous:Count},:if-changed" + }, + { + name = "cass.ks.{name}" + tags = [ + { + key = "keyspace" + value = "{keyspace}" + }, + { + key = "familyType" + value = "{type}" + }, + { + key = "statistic" + value = "percentile_99.9" + }, + { + key = "atlas.dstype" + value = "gauge" + } + ] + value = "{999thPercentile},1e6,:div,{Count},{previous:Count},:if-changed" + } + ] + }, + // // type=ColumnFamily //