glassfish
  1. glassfish
  2. GLASSFISH-16706

GF-Weld integration layer fails to load class from wab fragments

    Details

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

      Description

      Use latest 3.1.1 builds. Unzip the attached zip to domain1/autodeploy/bundles and you will see the exception below:

      [#|2011-05-23T22:09:07.825+0530|SEVERE|glassfish3.2|org.glassfish.weld.BeanDeploymentArchiveImpl|_ThreadID=13;_ThreadName=pool-8-thread-1;|ghterfish.sample.uas.simplewabfragment.ReportServlet
      java.lang.ClassNotFoundException: ghterfish.sample.uas.simplewabfragment.ReportServlet
      at java.lang.ClassLoader.findClass(ClassLoader.java:359)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
      at com.sun.enterprise.v3.server.APIClassLoaderServiceImpl$APIClassLoader.loadClass(APIClassLoaderServiceImpl.java:196)
      at com.sun.enterprise.v3.server.APIClassLoaderServiceImpl$APIClassLoader.loadClass(APIClassLoaderServiceImpl.java:172)
      at org.glassfish.osgiweb.OSGiWebDeploymentContext$WABClassLoader.loadClass(OSGiWebDeploymentContext.java:138)
      at org.glassfish.osgiweb.OSGiWebDeploymentContext$WABClassLoader.loadClass(OSGiWebDeploymentContext.java:121)
      at org.glassfish.weld.BeanDeploymentArchiveImpl.populate(BeanDeploymentArchiveImpl.java:340)
      at org.glassfish.weld.BeanDeploymentArchiveImpl.<init>(BeanDeploymentArchiveImpl.java:148)
      at org.glassfish.weld.BeanDeploymentArchiveImpl.<init>(BeanDeploymentArchiveImpl.java:128)
      at org.glassfish.weld.DeploymentImpl.<init>(DeploymentImpl.java:120)
      at org.glassfish.weld.WeldDeployer.load(WeldDeployer.java:334)
      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:462)
      at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
      at org.glassfish.osgijavaeebase.OSGiDeploymentRequest.deploy(OSGiDeploymentRequest.java:183)
      at org.glassfish.osgijavaeebase.OSGiDeploymentRequest.execute(OSGiDeploymentRequest.java:118)
      at org.glassfish.osgijavaeebase.AbstractOSGiDeployer.deploy(AbstractOSGiDeployer.java:121)
      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:619)

      #]

      For some reason, GF-Weld integration layer is failing to load class from an attached fragment.

        Activity

        Hide
        Sanjeeb Sahoo added a comment -

        Test case. Unzip it.

        Show
        Sanjeeb Sahoo added a comment - Test case. Unzip it.
        Hide
        Sivakumar Thyagarajan added a comment -

        Need to investigate and fix in 3.1.1. So marking it with tag 3_1_1-review

        Show
        Sivakumar Thyagarajan added a comment - Need to investigate and fix in 3.1.1. So marking it with tag 3_1_1-review
        Hide
        Sivakumar Thyagarajan added a comment -

        For classes and resources in WAB fragments, the classes do not lie under WEB-INF/classes. The Bean classes processing logic in BeanDeploymentArchiveImpl assumes that the classes within a WAR are always prefixed with "WEB-INF/classes" and so WAB fragment processing fails. Need to fix the logic in BeanDeploymentArchiveImpl.populate.

        Show
        Sivakumar Thyagarajan added a comment - For classes and resources in WAB fragments, the classes do not lie under WEB-INF/classes. The Bean classes processing logic in BeanDeploymentArchiveImpl assumes that the classes within a WAR are always prefixed with "WEB-INF/classes" and so WAB fragment processing fails. Need to fix the logic in BeanDeploymentArchiveImpl.populate.
        Hide
        Sivakumar Thyagarajan added a comment - - edited

        Component Name: OSGi-CDI
        Issue: http://java.net/jira/browse/GLASSFISH-16706

        • Why fix this issue in 3.1.1?

        Affects OSGi/Java EE WAB Fragments. Deployment of the WAB fragment would fail.

        • Which is the targeted build of 3.1.1 for this fix?

        3.1.1 b08

        • Do regression tests exist for this issue?

        Yes, the test included in this bug report. I will also add a developer test in the CDI devtests suite to cover WAB fragment scenarios.

        • Which tests should QA (re)run to verify the fix did not destabilize GlassFish?

        Fighterfish tests? Sahoo, please add to this if there are other tests QA has committed to build/run in 3.1.1.

        Show
        Sivakumar Thyagarajan added a comment - - edited Component Name: OSGi-CDI Issue: http://java.net/jira/browse/GLASSFISH-16706 Why fix this issue in 3.1.1? Affects OSGi/Java EE WAB Fragments. Deployment of the WAB fragment would fail. Which is the targeted build of 3.1.1 for this fix? 3.1.1 b08 Do regression tests exist for this issue? Yes, the test included in this bug report. I will also add a developer test in the CDI devtests suite to cover WAB fragment scenarios. Which tests should QA (re)run to verify the fix did not destabilize GlassFish? Fighterfish tests? Sahoo, please add to this if there are other tests QA has committed to build/run in 3.1.1.
        Hide
        Sivakumar Thyagarajan added a comment -

        Fixed in 3.1.1 as part of svn commit 47614 and in trunk as part of svn commit 47615

        Show
        Sivakumar Thyagarajan added a comment - Fixed in 3.1.1 as part of svn commit 47614 and in trunk as part of svn commit 47615

          People

          • Assignee:
            Sivakumar Thyagarajan
            Reporter:
            Sanjeeb Sahoo
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: