glassfish
  1. glassfish
  2. GLASSFISH-15095

Nucleus distribution is completely broken - can't start because of missing grizzly comet packages

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 3.1_b31
    • Fix Version/s: 3.1_b33
    • Component/s: grizzly-kernel
    • Labels:
      None

      Description

      After addressing issue 15093 and 15094, I now face this problem while starting nucleus:

      WARNING: Exception while starting bundle org.glassfish.core.kernel [53]
      org.osgi.framework.BundleException: Unresolved constraint in bundle org.glassfish.core.kernel [53]: Unable to resolve 53.0: missing requirement [53.0] package; (&(package=com.sun.enterprise.admin.util)(version>=3.1.0)) [caused by: Unable to resolve 55.0: missing requirement [55.0] package; (&(package=com.sun.enterprise.config.serverbeans)(version>=3.1.0)) [caused by: Unable to resolve 14.0: missing requirement [14.0] package; (&(package=com.sun.grizzly.config.dom)(version>=1.9.0)) [caused by: Unable to resolve 12.0: missing requirement [12.0] package; (&(package=com.sun.grizzly.comet)(version>=1.9.24))]]]
      at org.apache.felix.framework.Felix.resolveBundle(Felix.java:3404)
      at org.apache.felix.framework.Felix.startBundle(Felix.java:1714)
      at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:922)
      at org.jvnet.hk2.osgimain.Main.start(Main.java:154)
      at org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:633)
      at org.apache.felix.framework.Felix.activateBundle(Felix.java:1822)
      at org.apache.felix.framework.Felix.startBundle(Felix.java:1739)
      at org.apache.felix.framework.Felix.setActiveStartLevel(Felix.java:1143)
      at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:264)
      at java.lang.Thread.run(Thread.java:619)

      Looking at OSGi cache, I see bundle 12 is grizzly-config.jar and it indeed imports grizzly comet packages. Why? It was not importing comet packages earlier - not at least in the version of grizzly-config distributed in glassfish 3.0.1.

      1. osgi.bundle
        2 kB
        Justin Lee
      2. pom.xml
        7 kB
        Justin Lee
      3. pom.xml
        20 kB
        Justin Lee

        Issue Links

          Activity

          Hide
          Sanjeeb Sahoo added a comment - - edited

          Come on. How can one go by dates alone to confirm what was integrated in gfv3.0.1? You mean every change happening now in any part of grizzly codebase is getting integrated in gf3.1? I just saw they have a 3.2 like branch where they are doing something which is probably not being part of gf3.1. Something like that must have happened in 3.0.x timeframe as well or the dependency was once introfuced in 3.0.x times frame which was removed by the time 3.0.1 was FCSed. I kind of remember Jerome raising this issue once.

          Fortunately, source code control systems don't forget. Here is what I see:

          GF3.0.1 FCS is shipped with grizzly-config version 1.9.18-o. If you don't trust me, go download 3.0.1 fcs and look at the manifest of grizzly-config.jar that's there.

          Currently the version of grizzly-config that's integrated with GF3.1 trunk is 1.9.24.

          Now, compare the versions that are really used in gf3.0.1 fcs and gf3.1 trunk:

          ss141213@Sahoo:/space/ss141213/WS/grizzly/v1.9.24/modules/config$ svn diff https://svn.java.net/svn/grizzly~svn/tags/1_9_18o/modules/config/src/main/java/com/sun/grizzly/config/GrizzlyEmbeddedHttp.java https://svn.java.net/svn/grizzly~svn/tags/1_9_24/modules/config/src/main/java/com/sun/grizzly/config/GrizzlyEmbeddedHttp.java | grep -i comet
          +import com.sun.grizzly.comet.CometAsyncFilter;

          • final boolean mayEnableComet = !"admin-listener".equalsIgnoreCase(networkListener.getName());
          • configureProtocol(networkListener, protocol, habitat, mayEnableComet);
          • boolean mayEnableComet) {
          • if (mayEnableComet && (GrizzlyConfig.toBoolean(http.getCometSupportEnabled()) || Boolean
          • .getBoolean("v3.grizzly.cometSupport"))) {
            + if (mayEnableAsync && (GrizzlyConfig.toBoolean(http.getCometSupportEnabled()) ||
            + Boolean.getBoolean("v3.grizzly.cometSupport"))) {
            configureComet(habitat);
          • habitat, mayEnableComet);
          • private final void configureComet(Habitat habitat) {
          • final AsyncFilter cometFilter = habitat.getComponent(AsyncFilter.class, "comet");
          • if (cometFilter != null) {
            + private void configureComet(Habitat habitat) {
            + enableAsyncHandler(habitat, "comet", CometAsyncFilter.class);
          • asyncHandler.addAsyncFilter(cometFilter);

          More over,
          ss141213@Sahoo:/space/ss141213/WS/grizzly/v1.9.24/modules/config$ svn annotate ./src/main/java/com/sun/grizzly/config/GrizzlyEmbeddedHttp.java | grep comet
          4222 cheeser import com.sun.grizzly.comet.CometAsyncFilter;

          I think someone has also introduced websocket dependency lately in grizzly-config.

          Show
          Sanjeeb Sahoo added a comment - - edited Come on. How can one go by dates alone to confirm what was integrated in gfv3.0.1? You mean every change happening now in any part of grizzly codebase is getting integrated in gf3.1? I just saw they have a 3.2 like branch where they are doing something which is probably not being part of gf3.1. Something like that must have happened in 3.0.x timeframe as well or the dependency was once introfuced in 3.0.x times frame which was removed by the time 3.0.1 was FCSed. I kind of remember Jerome raising this issue once. Fortunately, source code control systems don't forget. Here is what I see: GF3.0.1 FCS is shipped with grizzly-config version 1.9.18-o. If you don't trust me, go download 3.0.1 fcs and look at the manifest of grizzly-config.jar that's there. Currently the version of grizzly-config that's integrated with GF3.1 trunk is 1.9.24. Now, compare the versions that are really used in gf3.0.1 fcs and gf3.1 trunk: ss141213@Sahoo:/space/ss141213/WS/grizzly/v1.9.24/modules/config$ svn diff https://svn.java.net/svn/grizzly~svn/tags/1_9_18o/modules/config/src/main/java/com/sun/grizzly/config/GrizzlyEmbeddedHttp.java https://svn.java.net/svn/grizzly~svn/tags/1_9_24/modules/config/src/main/java/com/sun/grizzly/config/GrizzlyEmbeddedHttp.java | grep -i comet +import com.sun.grizzly.comet.CometAsyncFilter; final boolean mayEnableComet = !"admin-listener".equalsIgnoreCase(networkListener.getName()); configureProtocol(networkListener, protocol, habitat, mayEnableComet); boolean mayEnableComet) { if (mayEnableComet && (GrizzlyConfig.toBoolean(http.getCometSupportEnabled()) || Boolean .getBoolean("v3.grizzly.cometSupport"))) { + if (mayEnableAsync && (GrizzlyConfig.toBoolean(http.getCometSupportEnabled()) || + Boolean.getBoolean("v3.grizzly.cometSupport"))) { configureComet(habitat); habitat, mayEnableComet); private final void configureComet(Habitat habitat) { final AsyncFilter cometFilter = habitat.getComponent(AsyncFilter.class, "comet"); if (cometFilter != null) { + private void configureComet(Habitat habitat) { + enableAsyncHandler(habitat, "comet", CometAsyncFilter.class); asyncHandler.addAsyncFilter(cometFilter); More over, ss141213@Sahoo:/space/ss141213/WS/grizzly/v1.9.24/modules/config$ svn annotate ./src/main/java/com/sun/grizzly/config/GrizzlyEmbeddedHttp.java | grep comet 4222 cheeser import com.sun.grizzly.comet.CometAsyncFilter; I think someone has also introduced websocket dependency lately in grizzly-config.
          Hide
          Dhiru Pandey added a comment -

          You are correct Sahoo - my reasoning for this was erroneous. I too verified that comet packages were not imported in 3.0.1 ... it appears that this was introduced in 3.1.

          I am not sure what is the extent of change required to fix this issue - I will let the Grizzly team investigate that. I wish this issue was brought up earlier in the development cycle - rather than few days before HCF (MS7)

          I am curious though - what are the issue(s) with Nucleus distribution including comet ?

          Show
          Dhiru Pandey added a comment - You are correct Sahoo - my reasoning for this was erroneous. I too verified that comet packages were not imported in 3.0.1 ... it appears that this was introduced in 3.1. I am not sure what is the extent of change required to fix this issue - I will let the Grizzly team investigate that. I wish this issue was brought up earlier in the development cycle - rather than few days before HCF (MS7) I am curious though - what are the issue(s) with Nucleus distribution including comet ?
          Hide
          Sanjeeb Sahoo added a comment -

          I won't be surprised if someone actually tells me comet dependency was included earlier only to be subsequently removed by the time v3.0.1 was fcsed.

          I have addressed the two other nucleus issues after I discovered them that night. Until this is actually fixed (which does not seem difficult given it was once removed earlier), I can't tell what other issues are with nucleus. This is a blocker. I doubt there are many issues with nucleus at this point of time though.

          Show
          Sanjeeb Sahoo added a comment - I won't be surprised if someone actually tells me comet dependency was included earlier only to be subsequently removed by the time v3.0.1 was fcsed. I have addressed the two other nucleus issues after I discovered them that night. Until this is actually fixed (which does not seem difficult given it was once removed earlier), I can't tell what other issues are with nucleus. This is a blocker. I doubt there are many issues with nucleus at this point of time though.
          Hide
          oleksiys added a comment -

          we have a fix.
          Ryan will integrate the Grizzly 1.9.26 and close the issue.

          Show
          oleksiys added a comment - we have a fix. Ryan will integrate the Grizzly 1.9.26 and close the issue.
          Hide
          Ryan Lubke added a comment -

          Grizzly 1.9.26 has been integrated (revision 43797).

          Show
          Ryan Lubke added a comment - Grizzly 1.9.26 has been integrated (revision 43797).

            People

            • Assignee:
              Ryan Lubke
              Reporter:
              Sanjeeb Sahoo
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: