Thanks for the reply, Jo.

The java library is developed by my team. Our java library doesn’t know about 
the main program (various clients applications). And the original goal for 
using SLF4J is logging for our java library, not for the main program(clients 
applications). I want to keep one version of our java library, in other words, 
having just one JAR file, (not multiple versions of JARs with different 
bindings). Is that possible?
And between the binding used in our java library and the logging framework used 
by a client's application, if they are different, will it cause any 
error/problem? 
Thanks. 



-----Original Message-----
From: slf4j-user [mailto:[email protected]] On Behalf Of Joachim 
Durchholz
Sent: Wednesday, February 22, 2017 4:55 PM
To: [email protected]
Subject: Re: [slf4j-user] Question on SLF4J - binding

On 22.02.2017 22:40, Chen, Richard - 2 wrote:
> Since I am bind to simple, I understand logging wouldn’t work, but 
> will it cause any errors/issues for having it bind to simple?

Since the backend is a per-application decision, that decision should be made 
by the main program, not by any library (SLF4J was built specifically to allow 
libraries to do logging without committing to a specific backend).

If you want to see log output from your test code, then your test code should 
bind to a backend, yes.

That's why you typically add logging backends to the "test" scope in
Maven: These are used just during testing and not made part of the generated 
jar files.

HTH
Jo
_______________________________________________
slf4j-user mailing list
[email protected]
http://mailman.qos.ch/mailman/listinfo/slf4j-user

----------------------------------------------------------------------
This message, and any attachments, is for the intended recipient(s) only, may 
contain information that is privileged, confidential and/or proprietary and 
subject to important terms and conditions available at 
http://www.bankofamerica.com/emaildisclaimer.   If you are not the intended 
recipient, please delete this message.
_______________________________________________
slf4j-user mailing list
[email protected]
http://mailman.qos.ch/mailman/listinfo/slf4j-user

Reply via email to