glassfish
  1. glassfish
  2. GLASSFISH-17246

SLF4J API conflicts with org.glassfish.weld.WeldDeployer

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Duplicate
    • Affects Version/s: 3.1.1
    • Fix Version/s: None
    • Component/s: cdi
    • Labels:
      None
    • Environment:

      Ubuntu Linux 10.04 LTS, Glassfish 3.1.1, SLF4J API 1.6.1..1.6.2, logback classic 0.9.29

      Description

      Described in

      http://old.nabble.com/HybridApplication-WeldBootstrap-Error-td32335499.html#a32340492

      The deployment of my ejb bundle (hybrid application) fails, cause org.glassfish.weld.WeldDeployer throws an error.

      server.log
      2011-08-26T08:28:17.139+0200   WARNING
      org.glassfish.osgijavaeebase                                     
      Failed to deploy bundle de.sgbs.geo.service [386]
      org.glassfish.osgijavaeebase.DeploymentException: Deployment of de.sgbs.geo.service [386] failed because of following reason: Failed while deploying bundle de.sgbs.geo.service [386] : java.lang.RuntimeException: Failed to deploy bundle [ de.sgbs.geo.service [386] ], root cause: Exception while loading the app
      	at org.glassfish.osgijavaeebase.AbstractOSGiDeployer.deploy(AbstractOSGiDeployer.java:125)
      	at org.glassfish.osgijavaeebase.OSGiContainer.deploy(OSGiContainer.java:154)
      	at org.glassfish.osgijavaeebase.JavaEEExtender.deploy(JavaEEExtender.java:107)
      	at org.glassfish.osgijavaeebase.JavaEEExtender.access$200(JavaEEExtender.java:61)
      	at org.glassfish.osgijavaeebase.JavaEEExtender$HybridBundleTrackerCustomizer$1.call(JavaEEExtender.java:151)
      	at org.glassfish.osgijavaeebase.JavaEEExtender$HybridBundleTrackerCustomizer$1.call(JavaEEExtender.java:148)
      	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      	at java.lang.Thread.run(Thread.java:662)
      Caused by: java.lang.RuntimeException: Failed to deploy bundle [ de.sgbs.geo.service [386] ], root cause: Exception while loading the app
      	at org.glassfish.osgijavaeebase.OSGiDeploymentRequest.deploy(OSGiDeploymentRequest.java:196)
      	at org.glassfish.osgijavaeebase.OSGiDeploymentRequest.execute(OSGiDeploymentRequest.java:118)
      	at org.glassfish.osgijavaeebase.AbstractOSGiDeployer.deploy(AbstractOSGiDeployer.java:121)
      	... 10 more
      Caused by: java.lang.NoSuchMethodError: org.slf4j.spi.LocationAwareLogger.log(Lorg/slf4j/Marker;Ljava/lang/String;ILjava/lang/String;Ljava/lang/Throwable;)V
      	at org.slf4j.cal10n.LocLogger.info(LocLogger.java:122)
      	at org.jboss.weld.bootstrap.WeldBootstrap.(WeldBootstrap.java:213)
      	at org.glassfish.weld.WeldDeployer.load(WeldDeployer.java:345)
      	at org.glassfish.weld.WeldDeployer.load(WeldDeployer.java:99)
      	at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:186)
      	at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:257)
      	at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:461)
      	at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
      	at org.glassfish.osgijavaeebase.OSGiDeploymentRequest.deploy(OSGiDeploymentRequest.java:183)
      	... 12 more
      

      I use SLF4J to route OSGi LogEntry to logback. This is not possible anymore, because after each restart of the application server the above error is thrown. Uninstalling slf4j api as bundle and it works again. Proposal: Separate slf4j with org.glassfish.weld, so other users can use slf4j.

        Issue Links

          Activity

          There are no comments yet on this issue.

            People

            • Assignee:
              Sivakumar Thyagarajan
              Reporter:
              cinhtau
            • Votes:
              2 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: