-
-
Notifications
You must be signed in to change notification settings - Fork 925
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
beyond JRuby's StandardErrorLogger #3469
Conversation
83f68c1
to
f180fbd
Compare
So one comment is that the use of debug("foo {}", argument) should be a net I was also worried when I saw some static final DEBUGs disappear but I see @kares my main question is how could us including slf4j end up affecting -Tom On Mon, Feb 22, 2016 at 10:58 PM, Karol Bucek notifications@github.com
blog: http://blog.enebo.com twitter: tom_enebo |
@enebo the old way of static final checks can stay here and there - removed some that are useful in embed (e.g. while running with jruby-rack its annoying to always have to look for System.out / err) we do not include SLF4J ... its an optional dependency and would need to be manually added, a SLF4J logger impl (SLF4J only required to have it compiled) is provided but anyone willing to use it must add and setup SLF4J on their own and use the 'new' |
@kares thanks for the explanation. This all looked fine with what I saw. On Tue, Feb 23, 2016 at 9:13 AM, Karol Bucek notifications@github.com
blog: http://blog.enebo.com twitter: tom_enebo |
@enebo thanks for the review, will wait for another 🚦 - as I do not want to force this on you unless you are comfortable with the change (tried to make sure it works out-of-the box the same way as so far). |
@headius how's this looking for you? |
@headius 🎱 still want this reviewed ... 💭 please |
8d82307
to
6e5b671
Compare
release is getting close ... should we still wait for @headius to get us a review ? |
* added a OutputStreamLogger base-class * improved {} parameter substitution performance (and failure reporting) * message+throwable writes are synchronized to make sure they stay together
… on Ruby land ... e.g. with "daemonizing" libraries that also replace Java's System.err but after JRuby has been loaded
…ssage e.g. : 2015-11-04T11:29:41.759+01:00 [main] INFO SampleLogger : hello world
…skipped this is for delegated logging such as with SLF4J where we do not want to pollute the "default" logger name space + it's also easier to set logging verbosity for org.jruby.xxx
…ing a class down ... default std-err logging will still behave the same - using only the class simple name but delegated loggers such as SLF4J will have the desired package parent structure
this way logging will work as expected with delegated logging such as SLF4J as well
…to read) array.to_s
merged in to have |
improvements and some new features for JRuby's internal logging
there seems to be a lot of commits but usually with little change - did not want to squash them as some of them have detailed messages.
... gist of changes :
-Xlog.backtraces
can get hard to read with multiple threads ... targeted for jruby-1_7 log exception backtrace in one log record #3403 as well-Xlog.callers
isdouble logged andhard to read with ato_s
array formatting - this is changed to use MRI backtrace formattingSystem.err
which causes the StandardErrorLogger to print "nowhere" if JRuby's classes are loaded before the stream change - we'll know allways read theSystem.err
field2015-11-04T11:29:41.759+01:00 [main] INFO SampleLogger : hello world
... includes thread-name and level compared to current stateLoggerFactory.getLogger(Class)
is introduced and should be preferred of the(String)
version so that one could potentially configure loggers easily e.g. for the wholeorg.jruby.xxx
package. note that default logger still behave the same and only uses simple name of the class as the logger name