[jboss-jira] [JBoss JIRA] (JGRP-1585) Upgrade log4j

David Lloyd (JIRA) jira-events at lists.jboss.org
Wed Feb 6 11:09:51 EST 2013


    [ https://issues.jboss.org/browse/JGRP-1585?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12752604#comment-12752604 ] 

David Lloyd commented on JGRP-1585:
-----------------------------------

Programming against an API is a good idea.  Log4j does suck pretty badly, hence our replacement of it inside of AS as a backend.  I won't rehash any arguments but I do want to point out (again) a few options:

* JBoss Logging is a nice clean API and easy to use, and works against any backend (auto-detected); only one JAR is needed (plus the selected backend JAR, if any; if none is present then plain JUL is used).
* SLF4J is simple though not as fully-featured, but requires an impl JAR (this API is also supported in AS)
* Coding to the log4j API will still work in AS (we have our own implementation which uses our own backend).

If you use either of the first two approaches, you can bundle jboss-logmanager for your tests (if your tests entail logging) and get some nicely formatted output with pretty easy config, and good performance as well.  It works for the third approach as well but it's complex enough that you probably wouldn't want to bother with it.
                
> Upgrade log4j
> -------------
>
>                 Key: JGRP-1585
>                 URL: https://issues.jboss.org/browse/JGRP-1585
>             Project: JGroups
>          Issue Type: Task
>            Reporter: Bela Ban
>            Assignee: Bela Ban
>             Fix For: 3.3
>
>
> log4j has some heavy synchronization, which can sometimes lead to code blocking up to 30 seconds (see [1]).
> Investigate whether we should switch to log42 [2]. Perhaps we can simply program against the API (30K) and not even ship the implementation ?
> [1] https://issues.apache.org/bugzilla/show_bug.cgi?id=51047
> [2] http://logging.apache.org/log4j/2.x/

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list