Uploaded image for project: 'Geronimo'
  1. Geronimo
  2. GERONIMO-6479

Top-level log4j.jar issue

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 3.0.0
    • None
    • None
    • Security Level: public (Regular issues)
    • None

    Description

      We want to place our log4j jar file (log4j-1.2.17) in the top-level lib directory of our J2EE application. The goal is to make our version of log4j and our log4j.xml configuration available to all sub projects in our J2EE application. We have added a <hidden-classes> in geronimo-application.xml. But it doesn't work. Our application cann't start because it couldn't find the class files in our log4j-1.2.17.jar file.

      The error is below
      null: Cannot validate jar:
      org.apache.log4j.CategoryKey
      at org.apache.geronimo.openejb.deployment.EjbModuleBuilder.getAppInfo(EjbModuleBuilder.java:899)
      at org.apache.geronimo.openejb.deployment.EjbModuleBuilder.doInitContext(EjbModuleBuilder.java:796)
      at org.apache.geronimo.openejb.deployment.EjbModuleBuilder.initContext(EjbModuleBuilder.java:775)
      at org.apache.geronimo.j2ee.deployment.EARConfigBuilder.buildConfiguration(EARConfigBuilder.java:686)
      at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:256)
      at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:140)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
      Impl.java:25)
      at org.apache.geronimo.gbean.runtime.ReflectionMethodInvoker.invoke(Reflect
      ionMethodInvoker.java:34)
      at org.apache.geronimo.gbean.runtime.GBeanOperation.invoke(GBeanOperation.j
      ava:131)
      at org.apache.geronimo.gbean.runtime.GBeanInstance.invoke(GBeanInstance.jav
      a:883)
      at org.apache.geronimo.kernel.basic.BasicKernel.invoke(BasicKernel.java:245)
      at org.apache.geronimo.deployment.plugin.local.AbstractDeployCommand.doDeploy(AbstractDeployCommand.java:116)
      at
      org.apache.geronimo.deployment.plugin.local.DistributeCommand.run(DistributeCommand.java:61)
      at java.lang.Thread.run(Thread.java:736)

      The temp solution is below.
      1. add this line into your <geronimo-home>\etc\system.properties
      log4j.defautInitOverride=true
      2. start the server, and deploy the application.

      We need a solid solution

      Attachments

        Activity

          People

            Unassigned Unassigned
            xiezhi xiezhi
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: