Thanks for your help. I understand that this is not a typical use case and that it could be an expensive query.
{
"servers" : [ {
"port" : "1105",
"host" : "localhost",
"queries" : [ {
"obj" : "\"push.2879\":name=\"duration\",type=\"\"",
"outputWriters" : [ {
"@class" : "com.googlecode.jmxtrans.model.output.GraphiteWriter",
"settings" : {
"port" : 10000,
"host" : "localhost",
"rootPrefix" : "jmx",
"typeNames" : ["name"]
}
} ]
} ]
}]}
If I look in jmxtrans.log then I can see lines like: DEBUG (com.googlecode.jmxtrans.util.JmxUtils:195) - Executing queryName: XXXXXX
for all of the MBeans so it looks like your expectation was correct in how the empty string would be passed in and jmxtrans does appear to be seeing all the data.
However if I look at the graphite output it appeared to just contain a single MBean's output.
I next tried parsing jmxtrans.log, pulling out all the obj names like: "java.lang:name=PS Eden Space,type=MemoryPool" and putting them:
1. within separate queries in a single JSON
2. as separate files in /var/lib/json (same server host and port in each file but different single queries)
In these cases the output still looks like it's just a single MBean, but, if I stop jmxtrans then suddenly the others flow across as if GraphiteWriter was queueing them up somehow.
Any ideas on things I could try to change to get all the different values to "flush" through correctly?
Thanks!
Conor
Just to make it clearer, in case number 2 I end up with multiple files that look something like the below but each with different obj specifications. This is the method that is getting me closest so far but much of the data only comes over port 10000 as jmxtrans is stopping:
{
"servers" : [ {
"port" : "1105",
"host" : "foo",
"alias" : "foo",
"queries" : [ {
"obj" : "java.lang:type=Memory",
"outputWriters" : [ {
"@class" : "com.googlecode.jmxtrans.model.output.GraphiteWriter",
"settings" : {
"port" : 10000,
"host" : "localhost",
"rootPrefix" : "jmx",
"typeNames" : ["name"]
}
} ]
} ]
}]}