ICEfaces
  1. ICEfaces
  2. ICE-5855

ear packaging issue in Netbeans enterprise application project

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Invalid
    • Affects Version/s: 2.0-Alpha3
    • Fix Version/s: None
    • Component/s: Tool Integrations
    • Labels:
      None
    • Environment:
      NB 6.9

      Description

      I have created a simple Java EE 6 Enterprise App using the latest ICEfaces NetBeans IDE integration.
      When I deploy my ear archive to Glassfish v3, I get the following error:

      SEVERE: Exception while invoking class com.sun.enterprise.web.WebApplication start method
       java.lang.Exception: java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: java.lang.NoClassDefFoundError: org/icefaces/context/DOMPartialViewContext
               at com.sun.enterprise.web.WebApplication.start(WebApplication.java:117)
               at org.glassfish.internal.data.EngineRef.start(EngineRef.java:126)
               at org.glassfish.internal.data.ModuleInfo.start(ModuleInfo.java:241)
               at org.glassfish.internal.data.ApplicationInfo.start(ApplicationInfo.java:236)
               at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:339)
               at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:183)
               at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:272)
               at com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:305)
               at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:320)
               at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1176)

      After having a look at the ear archive, it turns out that the icefaces-comps-compat.jar and icefaces.jar are not included in the EARs lib folder. Instead, they are included in the WARs WEB-INF/lib folder. The other required jars (icefaces-compat.jar, icepush.jar) are correctly packaged in the EARs lib folder.

        Activity

        Hide
        Liming Wu added a comment -

        For Java Web project there isn't any problem with created war file.

        But for EnterpriseApplication project the issue comes up. Normally for Enterprise Application, Enterprise Application project is first created, which actually create 2 subprojects ejb and web as well. ICEfaces framework is then added into the web subproject.

        If ejb and web are separately built, generated ejb.jar and war are all right. But if trying to build top level project, which creates ear contains ejb.jar and war, icepush.jar or icefaces.jar (may be icefaces-compat if compat mode) randomly gets extracted out of war file into ear (not all of them, but some of them with no pattern), which causes problem such as no icepush.jar found, etc.

        if users then manually add icefaces/icepush, which causes duplication.

        Looks like a bug in netbeans but I cannot proof it.

        For now use may need to manually edit library. Remember don't include duplicated icefaces** jar files

        Show
        Liming Wu added a comment - For Java Web project there isn't any problem with created war file. But for EnterpriseApplication project the issue comes up. Normally for Enterprise Application, Enterprise Application project is first created, which actually create 2 subprojects ejb and web as well. ICEfaces framework is then added into the web subproject. If ejb and web are separately built, generated ejb.jar and war are all right. But if trying to build top level project, which creates ear contains ejb.jar and war, icepush.jar or icefaces.jar (may be icefaces-compat if compat mode) randomly gets extracted out of war file into ear (not all of them, but some of them with no pattern), which causes problem such as no icepush.jar found, etc. if users then manually add icefaces/icepush, which causes duplication. Looks like a bug in netbeans but I cannot proof it. For now use may need to manually edit library. Remember don't include duplicated icefaces** jar files
        Hide
        Liming Wu added a comment -

        What we recommend is to put all icefaces related jars into ear's lib directory

        Show
        Liming Wu added a comment - What we recommend is to put all icefaces related jars into ear's lib directory
        Hide
        Liming Wu added a comment -

        Cannot reproduce.

        Show
        Liming Wu added a comment - Cannot reproduce.

          People

          • Assignee:
            Liming Wu
            Reporter:
            Liming Wu
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: