Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

workaround 'parse_value: Ignoring trailing garbage ".0"' #916

Open
skarap opened this issue Jan 27, 2015 · 6 comments
Open

workaround 'parse_value: Ignoring trailing garbage ".0"' #916

skarap opened this issue Jan 27, 2015 · 6 comments

Comments

@skarap
Copy link

skarap commented Jan 27, 2015

When using curl_json to monitor couchdb _stats values I get a lot of 'parse_value: Ignoring trailing garbage ".0" after derive value. Input string was "4392.0".' type errors. The problem is that reported values in json have a trailing ".0" even if those are integers (e.g. couchdb/auth_cache_hits/current).

What do you think about making couchdb ignore the trailing ".0" if the expected type is integer? I can probably do it in parse_value function in src/daemon/common.c .

@mfournier
Copy link

This issue was also reported to the mailing-list: http://mailman.verplant.org/pipermail/collectd/2014-August/006296.html

and somebody complained about it on IRC just now.

@mfournier mfournier added the Bug A genuine bug label Feb 27, 2015
@jespada
Copy link

jespada commented Feb 27, 2015

Indeed I'm experiencing the same problem, with the same component mentioned on the mailing-list

@schafik
Copy link

schafik commented May 24, 2015

experiencing same problem

@anowak
Copy link

anowak commented Aug 21, 2015

The same problem here. This message is emitted with INFO severity, so setting log level to notice can be sometimes used as a workaround.

@piotrskowron-scrive
Copy link

The same with postgresql monitroing
[2016-04-16 20:38:36] parse_value: Ignoring trailing garbage ".639" after derive value. Input string was "8.639".

@octo
Copy link
Member

octo commented Aug 6, 2016

IIuc, JSON only supports floating point values (and those poorly). When parsing JSON, we should probably either assume double and cast to derive_t or use libyajl for the job.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants