glassfish
  1. glassfish
  2. GLASSFISH-17257

[osgi] gogo shell is incorrectly initialized in embedded mode

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.1
    • Fix Version/s: 3.1.2_b02, 4.0
    • Component/s: OSGi
    • Labels:
      None

      Description

      When Gogo shell is started by GlassFish embedded in a running framework, the shell is started with default argument which has undesired behavior. It can be as bad as the shell stopping the framework. It is evident in some of our embedded tests where I see log messages like this coming from gogo shell:

      gosh: stopping framework
      gogo: IllegalStateException: Invalid BundleContext.
      at org.apache.felix.framework.BundleContextImpl.getBundle(BundleContextImpl.java:137)
      at org.apache.felix.gogo.shell.Shell.shutdown(Shell.java:183)
      at org.apache.felix.gogo.shell.Shell.gosh(Shell.java:170)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at org.apache.felix.gogo.runtime.Reflective.method(Reflective.java:136)
      at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:82)
      at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:469)
      at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:395)
      at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
      at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)
      at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)
      at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
      at org.apache.felix.gogo.shell.Activator.run(Activator.java:75)
      at java.lang.Thread.run(Thread.java:662)

        Activity

        Hide
        Sanjeeb Sahoo added a comment -

        3.1.2:
        Sending osgi-platforms/equinox/src/main/resources/glassfish/osgi/equinox/configuration/config.ini
        Sending osgi-platforms/felix/src/main/resources/glassfish/osgi/felix/conf/config.properties
        Transmitting file data ..
        Committed revision 49118.

        trunk:
        Sending osgi-platforms
        Sending osgi-platforms/equinox/src/main/resources/glassfish/osgi/equinox/configuration/config.ini
        Sending osgi-platforms/felix/pom.xml
        Sending osgi-platforms/felix/src/main/resources/glassfish/osgi/felix/conf/config.properties
        Transmitting file data ..
        Committed revision 49120.

        Show
        Sanjeeb Sahoo added a comment - 3.1.2: Sending osgi-platforms/equinox/src/main/resources/glassfish/osgi/equinox/configuration/config.ini Sending osgi-platforms/felix/src/main/resources/glassfish/osgi/felix/conf/config.properties Transmitting file data .. Committed revision 49118. trunk: Sending osgi-platforms Sending osgi-platforms/equinox/src/main/resources/glassfish/osgi/equinox/configuration/config.ini Sending osgi-platforms/felix/pom.xml Sending osgi-platforms/felix/src/main/resources/glassfish/osgi/felix/conf/config.properties Transmitting file data .. Committed revision 49120.

          People

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

            Dates

            • Created:
              Updated:
              Resolved: