I was playing with using Log4j2 JSONLayout to push logs into Logstash and on my setup it seems like Log4j is pushing out bad JSON. No comma's between objects when complete="true". I have no idea if this is a bug, if it's expected behavior, or if it's something upstream in jackson.
Here are the versions I am using: OpenJDK 1.7.0_71 (centos 6 64 bit) jackson-annotations-2.4.4.jar jackson-core-2.4.2.jar jackson-databind-2.4.2.jar log4j-api-2.1.jar log4j-core-2.1.jar Here's a gist of the code, config, and output. https://gist.github.com/packplusplus/07b33eb19cbd3538f7af If I used the File appender, I get the exact same output (except in a file). In an ideal world, there would be an append newline function like on the syslog appender, which would make the files and the sockets much easier to drive events off of (but that's getting a bit greedy). Anyone have any thoughts on if this is a bug, where it would be filed, or any work arounds? Patrick p.s. http://logging.apache.org/log4j/2.x/manual/layouts.html - Doesn't list JSONLayout in the manual menu on the left. Where do I file that? -- * Patrick **Flaherty *| * w:* *e:* [email protected]
