GraphiteWriterFactory does not actually write
See original GitHub issueThe GraphiteWriter
outputs to Graphite properly with a configuration like the following:
{
"servers" : [
{
"port" : "PPPPP",
"host" : "AAA.BBB.CCC",
"queries" : [
{
"outputWriters" : [
{
"@class" : "com.googlecode.jmxtrans.model.output.GraphiteWriter",
"rootPrefix" : "jmx",
"port" : "2003",
"host" : "127.0.0.1"
}
],
"obj" : "java.lang:type=Memory",
"attr" : [ "HeapMemoryUsage", "NonHeapMemoryUsage" ],
"resultAlias": "heap"
}
]
}
]
}
Changing the line
"@class" : "com.googlecode.jmxtrans.model.output.GraphiteWriter",
to
"@class" : "com.googlecode.jmxtrans.model.output.GraphiteWriterFactory",
let the output not working: no data reach the carbon-cache listener.
Excluding the deprecation of GraphiteWriter
, there is nothing strange in the log, even at DEBUG
level.
I found the behaviour in version 254 (I treid both .rpm and .jar flavour) and in version 255-SNAPSHOT20160511200238 (I tried rpm only).
Issue Analytics
- State:
- Created 7 years ago
- Comments:18 (3 by maintainers)
Top Results From Across the Web
YAML outputWriter config for GraphiteWriterFactory requires ...
When using outputWriters configuration in YAML settings wrapper key is required. Thus produced JSON config for GraphiteWriterFactory outputWriter is created ...
Read more >jmxtrans - Bountysource
I have now tried to add in simple attribute data collection for a JBOSS datasource/pool. JBOSS seems configured correctly, as when I run...
Read more >FileWriter is not writing into a file - java - Stack Overflow
You must close the FileWriter , otherwise it won't flush the current buffer. You can call the flush method directly.. fileWriter.flush() fileWriter.close().
Read more >All the things we can do with JMX - S. Derosiaux
JMX is an API used to expose data from any Java program to the outside. It's used by tons of softwares and libraries...
Read more >Use jmx-exporter && jmxtrans && nexus jmx exposed nexus ...
jmxtrans.json jmx query is a simple configuration, can be configured according to the actual. {. "servers": [{. "port": "8044",.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Always flushing is probably not a very good default. It would mean that we send a very small packet with a single metric each time a metric is collected. It is more efficient to batch multiple metrics in a single TCP packet. If you collect enough metrics, never flushing (and letting the underlying TCP implementation handle the buffering) is the most efficient choice. If you collect less metrics, flushing periodically make sense. It is more expensive, but allow you to get results in a timely fashion.
A better default might be to flush every minute.
I am currently testing these parameters and the Graphite database is receiving data using
GraphiteWriterFactory
. I leave the parameters running for some time, then I will report again.