[ 
https://issues.apache.org/jira/browse/UIMA-282?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12470884
 ] 

Michael Baessler commented on UIMA-282:
---------------------------------------

Some comments about this issue. 

UIMA internally don't use java.util.logging. UIMA has defined it's own logging 
architecture that fits most of the available Java logging architectures. So 
internally we use our own classes which can be wrapped to the Java logging 
system of your choice. The default wrapper we currently use is a wrapper for 
JSR47, but this can easily be changed to e.g. Log4J. You just have to provide 
the wrapper implementation and change the configuration settings that specifies 
which wrapper should be used.

The UIMA logging interface that is used internally is: 
org.apache.uima.util.Logger 

The JSR47 wrapper implementation is: org.apache.uima.util.impl.JSR47Logger_impl

The configuration which log wrapper should be used is available in: 
org.apache.uima.impl.factoryConfig.xml
There is a configuration setting like: <logger 
class="org.apache.uima.util.impl.JSR47Logger_impl"/> that must be changed to 
the new Log4J logger implementation.

So you see, it is not much effort to provide a log wrapper for Log4J. Maybe we 
can work together and provide such a logger implementation that implements the 
UIMA logging interface and uses Log4J as logging system, similar to the 
JSR47Logger_impl.
What do you think?




> Work well with Apache logging (Log4J)
> -------------------------------------
>
>                 Key: UIMA-282
>                 URL: https://issues.apache.org/jira/browse/UIMA-282
>             Project: UIMA
>          Issue Type: Wish
>            Reporter: Greg Holmberg
>            Priority: Minor
>
> UIMA uses the standard java.util.logging (JUL).  Most of my company's code 
> used Apache Log4J, so we have a problem merging the messages from the two 
> logging packages.  Given that UIMA is now an Apache project, I think it makes 
> sense that it work with Apache logging.
> Two options occur to me:
> 1. Change all the logging calls in the code (perhaps Eclipse refactoring 
> tools can help with that).  Here's some discussion on migrating: 
> http://www.oreillynet.com/onjava/blog/2005/12/migrating_from_jdk_logging_to.html
>  
> You could convert either to Log4J ( http://logging.apache.org/log4j/docs ) or 
> to Apache Jakarta Commons Logging ( http://jakarta.apache.org/commons/logging 
> ), which would allow UIMA to be configured to use either JUL or Log4J.
> 2. Write/find a JUL Handler that re-directs to Log4J.  Here's an example: 
> http://home.gwu.edu/~amrinder/chainsawHandler/UsingChainsawWithJDKLogging.html
>  

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to