The Logging Olympics: A Race Between Today’s Top 5 Logging Frameworks
takipiblog.com
takipiblog.com
We develop web applications and are happy users of sentry: https://getsentry.com/
And "useless micro-benchmark", which I'd hope is not the only factor going into picking a logging tool or API.
https://docs.google.com/spreadsheet/oimg?key=0AgScytvGrtowdG...
If you have to ask how much logging costs, you probably can't afford it.
I agree logging has to scale, but it doesn't look like there's any substantial difference between anything benchmarked (it'd have to be at least an order of magnitude for me to care).
The only options that I came across is a proprietary specification called CEF (common event format) and a dead project called CEE (common event expression) which IMO was over-engineered.
From a BI view the current logging formats could as well be /dev/random and this makes logging of somewhat limited use.
It's useful though when an admin reads individual log messages trying to debug an issue.
Really, you should always use slf4j, because all your libraries will be a mix of log4j, JUL, commons logging, etc, and slf4j will give you control over them all. It also comes with features some(log4j) of these dont have natively, like passing objects in args to do printf style replacement only when the log will be printed, instead of concatenation that always happens. Then use whatever backend you prefer, probably logback.
I don't care about the log statements that fire, those are always going to be too slow. I care about the overhead of all the log statements that don't fire that run for every single packet and transaction.
According to Mission Control/Flight recorder checking trace level logging statements was single digit percentages for me.
For us, logback+gelf was the right solution. Get the logs off the box and keep them intact. https://github.com/mp911de/logstash-gelf
(Separate: No one is using the javax JSON either).