Closed toni-moreno closed 7 years ago
I think this request is similar to PR #87 right?
Hi @grobian . This issue is similar but not exactly the same.
in https://github.com/grobian/carbon-c-relay/pull/87 , you will log "unwanted" this is metrics that you don't have any "match" rule.
In this issue what I need is a syntax check for valid metrics.
These metrics are valid metrics to graphite in "PlainText Format"
system.cpu.wait 80 1454056517
system.disk.io 25.0 1454056517
and these other are invalid to graphite
system.cpu.wait OK 1454056517 #bad value
system.cpu.wait OK 12343 #bad timestamp
system.cpu.wait 25 OK #bad timestamp
system cpu wait 25.0 1454056517 #bad number of parameters
Right now carbon-c-relay is relaying invalid metrics if a correct match rule found. I need to stop these invalid metrics before to reach the graphite backend.
I'm not sure if I understand, that is exactly what is requested in https://github.com/grobian/carbon-c-relay/pull/87 And partially implemented in https://github.com/piotr1212/carbon-c-relay/commits/filter2 @grobian made some changes since then and suggested to use a regex which is a much better idea than the ugly parsing I did...
@toni-moreno do you mean #78 (iso #87)? It's all a bit confusing right now :)
Hi @grobian what @piotr1212 have been done at https://github.com/grobian/carbon-c-relay/pull/87 is exactly what we need.
Thank you !!!
I've introduced a validate
clause to match rules
Could be interesting if c-relay could add a syntax filter avoiding sending malformed data:
"metric-name value timestamp"
to the graphite backend.
A logfile with this errors and the IP origin will be wellcomed also.
Thank you very much.