You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Alex Parvulescu (Created) (JIRA)" <ji...@apache.org> on 2012/01/26 14:54:42 UTC

[jira] [Created] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

NPE in WebConsole when trying to uninstall a bundle
---------------------------------------------------

                 Key: FELIX-3318
                 URL: https://issues.apache.org/jira/browse/FELIX-3318
             Project: Felix
          Issue Type: Bug
          Components: Web Console
            Reporter: Alex Parvulescu
            Priority: Minor


Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):

AJAX Error
The request failed: 


HTTP ERROR 500

Problem accessing /system/console/bundles/20. Reason:

    INTERNAL_SERVER_ERROR

Caused by:

java.lang.NullPointerException
	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
	at org.mortbay.jetty.Server.handle(Server.java:326)
	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
--------

I'm testing against a barebone felix install:

g! lb
START LEVEL 1
   ID|State      |Level|Name
    0|Active     |    0|System Bundle (4.0.1)
    1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
    2|Active     |    1|Apache Felix Gogo Command (0.12.0)
    3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
    4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
    5|Active     |    1|Apache Felix Log Service (1.0.1)
    6|Active     |    1|Apache Felix Http Bundle (2.2.0)
    7|Active     |    1|Apache Felix Http Jetty (2.2.0)
    8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
    9|Active     |    1|Apache Felix Metatype Service (1.0.4)
   15|Active     |    1|Apache Commons IO Bundle (1.4.0)
   16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
   17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
   23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)

I can install any bundle and then delete it and consistently see this error.



--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Felix Meschberger (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13193853#comment-13193853 ] 

Felix Meschberger commented on FELIX-3318:
------------------------------------------

Hmm, since the PackageAdminImpl.getBundleType method actually wants to have the BundleRevisionImpl class, it should probably ask for it. This should never return null, probably.
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-4.0.2
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Alex Parvulescu (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alex Parvulescu updated FELIX-3318:
-----------------------------------

    Attachment: FELIX-3318.patch

Not sure if this could be better fixed in the framework directly (in PackageAdminImpl), but here's a patch for the WebConsole code that handles the delete.

I just basically moved the isFragmentBundle check up, before the delete operation, this seems to fix the issue (or hide it better :)
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Web Console
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Alex Parvulescu (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13506500#comment-13506500 ] 

Alex Parvulescu commented on FELIX-3318:
----------------------------------------

I should have mentioned the framework version I'm using is 4.0.3.
the subtle difference I missed initially was this is a framework bug, not a Webconsole bug.
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-4.0.2
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Alex Parvulescu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13193852#comment-13193852 ] 

Alex Parvulescu commented on FELIX-3318:
----------------------------------------

Oups, forgot to mention that the delete actually happens. The NPE is apparently caused by the response string builder, that is why I moved the isFragmentBundle check up, before the uninstall op.
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-4.0.2
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Felix Meschberger (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Felix Meschberger updated FELIX-3318:
-------------------------------------

          Component/s:     (was: Web Console)
                       Framework
    Affects Version/s: framework-4.0.2

Reassigning to the framework -- this problem still exists in trunk
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-4.0.2
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Alex Parvulescu (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13506493#comment-13506493 ] 

Alex Parvulescu commented on FELIX-3318:
----------------------------------------

any updates on this?

I still see it with the WebConsole v4.0.0, identical trace

Problem accessing /system/console/bundles/15. Reason:
    INTERNAL_SERVER_ERROR
Caused by:
java.lang.NullPointerException
	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-4.0.2
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (FELIX-3318) NPE in WebConsole when trying to uninstall a bundle

Posted by "Felix Meschberger (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-3318?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13193849#comment-13193849 ] 

Felix Meschberger commented on FELIX-3318:
------------------------------------------

I think this is a bug in the PackageAdminImpl.getBundleType method: This calls adapt to get the BundleRevision of the bundle which returns null for uninstalled bundles (probably correctly). Yet this result is not checked in the getBundleType method and thus the NPE.
                
> NPE in WebConsole when trying to uninstall a bundle
> ---------------------------------------------------
>
>                 Key: FELIX-3318
>                 URL: https://issues.apache.org/jira/browse/FELIX-3318
>             Project: Felix
>          Issue Type: Bug
>          Components: Web Console
>            Reporter: Alex Parvulescu
>            Priority: Minor
>         Attachments: FELIX-3318.patch
>
>
> Tested against 3.18 and a trunk build (3.1.9.SNAPSHOT) as well. Both fail in the same way (stacktrace comes from trunk):
> AJAX Error
> The request failed: 
> HTTP ERROR 500
> Problem accessing /system/console/bundles/20. Reason:
>     INTERNAL_SERVER_ERROR
> Caused by:
> java.lang.NullPointerException
> 	at org.apache.felix.framework.PackageAdminImpl.getBundleType(PackageAdminImpl.java:112)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.isFragmentBundle(BundlesServlet.java:715)
> 	at org.apache.felix.webconsole.internal.core.BundlesServlet.doPost(BundlesServlet.java:358)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:473)
> 	at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:418)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
> 	at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
> 	at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
> 	at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
> 	at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
> 	at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
> 	at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
> 	at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
> 	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
> 	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
> 	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
> 	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
> 	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
> 	at org.mortbay.jetty.Server.handle(Server.java:326)
> 	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
> 	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
> 	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
> 	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
> 	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
> 	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
> 	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
> --------
> I'm testing against a barebone felix install:
> g! lb
> START LEVEL 1
>    ID|State      |Level|Name
>     0|Active     |    0|System Bundle (4.0.1)
>     1|Active     |    1|Apache Felix Bundle Repository (1.6.6)
>     2|Active     |    1|Apache Felix Gogo Command (0.12.0)
>     3|Active     |    1|Apache Felix Gogo Runtime (0.10.0)
>     4|Active     |    1|Apache Felix Gogo Shell (0.10.0)
>     5|Active     |    1|Apache Felix Log Service (1.0.1)
>     6|Active     |    1|Apache Felix Http Bundle (2.2.0)
>     7|Active     |    1|Apache Felix Http Jetty (2.2.0)
>     8|Active     |    1|Apache Felix Configuration Admin Service (1.2.8)
>     9|Active     |    1|Apache Felix Metatype Service (1.0.4)
>    15|Active     |    1|Apache Commons IO Bundle (1.4.0)
>    16|Active     |    1|Apache Commons FileUpload Bundle (1.2.1)
>    17|Active     |    1|Apache Geronimo Bundles: json-20090211 (20090211.0.0.1)
>    23|Active     |    1|Apache Felix Web Management Console (3.1.9.SNAPSHOT)
> I can install any bundle and then delete it and consistently see this error.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira