[logback-dev] [JIRA] Resolved: (LBCORE-100) logback fails to initialise when loaded from bootstrap classpath

Ceki Gulcu (JIRA) noreply-jira at qos.ch
Thu Jun 18 18:11:10 CEST 2009

     [ http://jira.qos.ch/browse/LBCORE-100?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ceki Gulcu resolved LBCORE-100.

    Fix Version/s: 0.9.16
       Resolution: Fixed

Thank you for this report. Fixed in revision 2297. 

> logback fails to initialise when loaded from bootstrap classpath
> ----------------------------------------------------------------
>                 Key: LBCORE-100
>                 URL: http://jira.qos.ch/browse/LBCORE-100
>             Project: logback-core
>          Issue Type: Bug
>    Affects Versions: 0.9.14
>            Reporter: Henric Larsson
>            Assignee: Logback dev list
>             Fix For: 0.9.16
>         Attachments: classloader.patch
> When logback is put in the endorsed library path of the jdk, it fails to initialise because the getClassLoader() call returns null in a couple of places.
> Returning null is expected when  the classloader is the bootstrap classloader, as is the case when logback is loaded from the endorsed directory.
> Here's a snippet from the sun jdk javadoc for Class.getClassLoader()
> "Returns the class loader for the class.  Some implementations may use null to represent the bootstrap class loader. This method will return null in such implementations if this class was loaded by the bootstrap class loader."
> I'm using jacorb 2.3.1, which uses slf4j-api 1.5.6. Jacorb is required to be in the endorsed lib to work, and hence any logging implementation has to go there too.
> I patched my logback instance to return the system classloader when the null classloader is encounterd.
> Attaching patch.

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the logback-dev mailing list