logspout-logstash
logspout-logstash copied to clipboard
Preserve JSON Number formating
When logging JSON numbers from docker, ex:{"value":1000000}
the value is converted to scientific notation once it's gone through the Marshall/Unmarshalling. ie:{"value":1e+06}
While this is not technically incorrect, it prevents us from looking for specific values in the logs (ids) without manually converting them to scientific notation.
I tried to come up with a fix myself (https://stackoverflow.com/a/22346593/8125689 looks promising), but while the issue definitely happens with the Bekt/logspout-logstash
image, I wasn't able to reproduce it in a test case 😕
PS: Loads of thanks for this project, we've been using it on production server for a while as part of our monitoring system and it does a pretty good job 👍
If anyone could do a PR I would be happy to merge it.