Skip to content
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

replace commons logging with slf4j? #156

Open
GoogleCodeExporter opened this issue Jun 4, 2015 · 1 comment
Open

replace commons logging with slf4j? #156

GoogleCodeExporter opened this issue Jun 4, 2015 · 1 comment

Comments

@GoogleCodeExporter
Copy link

It is much better to use slf4j than commons logging. It is possible for 
everyone to stick to their chosen implementation. As most frameworks use slf4j 
it is quite a hassle to work around commons logging using a dummy 
implementation.

Also note this article: http://articles.qos.ch/thinkAgain.html and the 
references at the bottom.

Original issue reported on code.google.com by hielke.hoeve on 17 Jun 2011 at 7:52

@GoogleCodeExporter
Copy link
Author

Agreed. Having libraries use slf4j as their facade simplifies integration, and 
the existence of slf4j-jcl means projects that want to stick with 
commons-logging just need to include that to bridge across.

The APIs are similar enough that the change is simply a matter of changing the 
logger definitions and importing the dependencies; patch attached.

On top of this, it may be worth using slf4j's parameterised logging to remove 
the 'if (DEBUG)' checks.

Original comment by [email protected] on 25 Feb 2015 at 2:36

Attachments:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant