Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-1637

OSGi support is broken in Log4j2 2.7

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.7
    • Fix Version/s: 2.8
    • Component/s: Core
    • Labels:
      None
    • Environment:

      Apache Felix, Java 8

      Description

      Log4j2 2.7 fails to initialise in an OSGi environement complaining that java.lang.NoClassDefFoundError: org/apache/logging/log4j/Logger.

      Running the OSGi tests on Log4j API also fails:
      org.apache.logging.log4j.osgi.felix.FelixLoadApiBundleTest
      testMissingImportOfCoreOsgiPackage(org.apache.logging.log4j.osgi.felix.FelixLoadApiBundleTest) Time elapsed: 1.031 sec <<< ERROR!
      org.osgi.framework.BundleException: Activator start error in bundle org.apache.logging.log4j.core [2].
      Caused by: java.lang.NoClassDefFoundError: org/apache/logging/log4j/Logger
      Caused by: java.lang.ClassNotFoundException: org.apache.logging.log4j.Logger not found by org.apache.logging.log4j.core [2]

      [... likewise for the other tests and equinox]

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                remkop@yahoo.com Remko Popma
                Reporter:
                lhochet Ludovic HOCHET
              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: