You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by "Eric Gulatee (JIRA)" <ji...@apache.org> on 2010/11/29 22:52:11 UTC

[jira] Created: (OPENEJB-1408) Allow another logging framework to be used

Allow another logging framework to be used
------------------------------------------

                 Key: OPENEJB-1408
                 URL: https://issues.apache.org/jira/browse/OPENEJB-1408
             Project: OpenEJB
          Issue Type: Wish
    Affects Versions: 3.1.4
            Reporter: Eric Gulatee


Would be nice not to force a logging framework.  
OpenEJB drags log4j into a project which causes issues.

If OpenEJB stuck to "Public" Log4J API, it would be possible to switch logging implementations using SLF4J & Wrappers.

Currently:

There is a HardCoded dependency on: org.apache.log4j.Layout



Caused by org.apache.log4j.Layout
java.net.URLClassLoader.findClass(URLClassLoader.java:497)
at java.lang.ClassLoader.loadClass(ClassLoader.java:639)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
at java.lang.ClassLoader.loadClass(ClassLoader.java:605)
at java.lang.J9VMInternals.verifyImpl(Native Method)
at java.lang.J9VMInternals.verify(J9VMInternals.java:69)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:131)
at org.apache.openejb.util.Logger.configure(Logger.java:61)
at org.apache.openejb.util.Logger.<clinit>(Logger.java:29) 


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


[jira] [Updated] (OPENEJB-1408) Allow another logging framework to be used

Posted by "Michael Glauche (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENEJB-1408?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Glauche updated OPENEJB-1408:
-------------------------------------

    Attachment: openejb-slf4j.patch

Patch to enable slf4j logging

> Allow another logging framework to be used
> ------------------------------------------
>
>                 Key: OPENEJB-1408
>                 URL: https://issues.apache.org/jira/browse/OPENEJB-1408
>             Project: OpenEJB
>          Issue Type: Wish
>    Affects Versions: 3.1.4
>            Reporter: Eric Gulatee
>         Attachments: openejb-slf4j.patch
>
>
> Would be nice not to force a logging framework.  
> OpenEJB drags log4j into a project which causes issues.
> If OpenEJB stuck to "Public" Log4J API, it would be possible to switch logging implementations using SLF4J & Wrappers.
> Currently:
> There is a HardCoded dependency on: org.apache.log4j.Layout
> Caused by org.apache.log4j.Layout
> java.net.URLClassLoader.findClass(URLClassLoader.java:497)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:639)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:605)
> at java.lang.J9VMInternals.verifyImpl(Native Method)
> at java.lang.J9VMInternals.verify(J9VMInternals.java:69)
> at java.lang.J9VMInternals.initialize(J9VMInternals.java:131)
> at org.apache.openejb.util.Logger.configure(Logger.java:61)
> at org.apache.openejb.util.Logger.<clinit>(Logger.java:29) 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Closed] (OPENEJB-1408) Allow another logging framework to be used

Posted by "Jean-Louis MONTEIRO (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENEJB-1408?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jean-Louis MONTEIRO closed OPENEJB-1408.
----------------------------------------

       Resolution: Fixed
    Fix Version/s: 4.0
         Assignee: Eric Gulatee

Committed for you.
Thanks!

> Allow another logging framework to be used
> ------------------------------------------
>
>                 Key: OPENEJB-1408
>                 URL: https://issues.apache.org/jira/browse/OPENEJB-1408
>             Project: OpenEJB
>          Issue Type: Wish
>    Affects Versions: 3.1.4
>            Reporter: Eric Gulatee
>            Assignee: Eric Gulatee
>             Fix For: 4.0
>
>         Attachments: openejb-slf4j.patch
>
>
> Would be nice not to force a logging framework.  
> OpenEJB drags log4j into a project which causes issues.
> If OpenEJB stuck to "Public" Log4J API, it would be possible to switch logging implementations using SLF4J & Wrappers.
> Currently:
> There is a HardCoded dependency on: org.apache.log4j.Layout
> Caused by org.apache.log4j.Layout
> java.net.URLClassLoader.findClass(URLClassLoader.java:497)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:639)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:605)
> at java.lang.J9VMInternals.verifyImpl(Native Method)
> at java.lang.J9VMInternals.verify(J9VMInternals.java:69)
> at java.lang.J9VMInternals.initialize(J9VMInternals.java:131)
> at org.apache.openejb.util.Logger.configure(Logger.java:61)
> at org.apache.openejb.util.Logger.<clinit>(Logger.java:29) 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OPENEJB-1408) Allow another logging framework to be used

Posted by "Michael Glauche (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OPENEJB-1408?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13014494#comment-13014494 ] 

Michael Glauche commented on OPENEJB-1408:
------------------------------------------

The attached patch provides a slf4j logging facility. To use it you'll need slf4-api in your classpath and add a line like this before the openejb server is started:

	System.setProperty("openejb.log.factory", "org.apache.openejb.util.Slf4jLogStreamFactory");

To exclude other logging frameworks needed by openejb or its dependencies i'm using the following with maven2:

		<dependency>
			<groupId>org.apache.openejb</groupId>
			<artifactId>openejb-core</artifactId>
			<version>3.1.4</version>
			<scope>test</scope>
			<!-- exclude logging libraries -->
				<exclusions>
					<exclusion>
						<groupId>commons-logging</groupId>
						<artifactId>commons-logging</artifactId>
					</exclusion>
					<exclusion>
						<groupId>log4j</groupId>
						<artifactId>log4j</artifactId>
					</exclusion>
				</exclusions>
		</dependency>


> Allow another logging framework to be used
> ------------------------------------------
>
>                 Key: OPENEJB-1408
>                 URL: https://issues.apache.org/jira/browse/OPENEJB-1408
>             Project: OpenEJB
>          Issue Type: Wish
>    Affects Versions: 3.1.4
>            Reporter: Eric Gulatee
>         Attachments: openejb-slf4j.patch
>
>
> Would be nice not to force a logging framework.  
> OpenEJB drags log4j into a project which causes issues.
> If OpenEJB stuck to "Public" Log4J API, it would be possible to switch logging implementations using SLF4J & Wrappers.
> Currently:
> There is a HardCoded dependency on: org.apache.log4j.Layout
> Caused by org.apache.log4j.Layout
> java.net.URLClassLoader.findClass(URLClassLoader.java:497)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:639)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:605)
> at java.lang.J9VMInternals.verifyImpl(Native Method)
> at java.lang.J9VMInternals.verify(J9VMInternals.java:69)
> at java.lang.J9VMInternals.initialize(J9VMInternals.java:131)
> at org.apache.openejb.util.Logger.configure(Logger.java:61)
> at org.apache.openejb.util.Logger.<clinit>(Logger.java:29) 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira