t0xa / gelfj

Graylog Extended Log Format (GELF) implementation in Java and log4j appender without any dependencies.
https://github.com/t0xa/gelfj/wiki
Other
186 stars 116 forks source link

Have to call stream.finish() with GZipOutputStream #21

Closed twinforces closed 12 years ago

twinforces commented 12 years ago

GZipOutputStream doesn't always return good results if you don't call stream.finish() before calling stream.close(). Weird, buggy, but true.

twinforces commented 12 years ago

Here's a link:

http://wondersofcomputing.blogspot.com/2010/02/gzipoutputstream-remember-to-finish.html

Note that the javadocs for GZipOutputStream show the finish() call as well.

t0xa commented 12 years ago

Thanks. Will do.

t0xa commented 12 years ago

Added.

twinforces commented 12 years ago

Hey, I have some other changes if you're interested to both simplify the code and make it work with non-blocking I/O. I didn't do it inside gelfj because I needed a Spring bean GelfSender, but let me know and I'll back port them to gelfj.

Added.


Reply to this email directly or view it on GitHub: https://github.com/t0xa/gelfj/issues/21#issuecomment-3833401