Uploaded image for project: 'ServiceMix'
  1. ServiceMix
  2. SM-2117

Fail to uninstall components after container restart

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.3.2
    • Fix Version/s: 3.4.0
    • Component/s: servicemix-core
    • Labels:
    • Environment:
    • Patch Info:
      Patch Available

      Description

      Components installed via ant tasks (org.apache.servicemix.jbi.framework.AdminCommandsService) are registered in installers map. Components loaded on container restart are registered in nonLoadedInstallers map. When component is ordered to be uninstalled via ant tasks (org.apache.servicemix.jbi.framework.AdminCommandsService) then it is looked up only in installers map and this lookup fails and false is returned without anything being actually done. If you get component list after that you'll be able to see that component is not uninstalled.

      Problem during Ant task execution
      java.lang.Exception: <?xml version="1.0" encoding="UTF-8"?>
      <jbi-task xmlns="http://java.sun.com/xml/ns/jbi/management-message" version="1.0">
      <jbi-task-result>
      <frmwk-task-result>
      <frmwk-task-result-details>
      <task-result-details>
      <task-id>uninstallComponent</task-id>
      <task-result>FAILED</task-result>
      <message-type>ERROR</message-type>
      <task-status-msg>
      <msg-loc-info>
      <loc-token/>
      <loc-message>servicemix-scripting</loc-message>
      </msg-loc-info>
      </task-status-msg>
      </task-result-details>
      </frmwk-task-result-details>
      </frmwk-task-result>
      </jbi-task-result>
      </jbi-task>

      at org.apache.servicemix.jbi.framework.ManagementSupport.failure(ManagementSupport.java:125)
      at org.apache.servicemix.jbi.framework.ManagementSupport.failure(ManagementSupport.java:107)
      at org.apache.servicemix.jbi.framework.AdminCommandsService.uninstallComponent(AdminCommandsService.java:89)
      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.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:216)
      at org.apache.servicemix.jbi.management.BaseStandardMBean.invoke(BaseStandardMBean.java:323)
      at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
      at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
      at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1427)
      at javax.management.remote.rmi.RMIConnectionImpl.access$200(RMIConnectionImpl.java:72)
      at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1265)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1367)
      at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:788)
      at sun.reflect.GeneratedMethodAccessor53.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305)
      at sun.rmi.transport.Transport$1.run(Transport.java:159)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
      at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
      at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
      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:662)

        Activity

        Hide
        nickolay_martinov Nikolay Martynov added a comment -

        Submitting patch that seems to help

        Show
        nickolay_martinov Nikolay Martynov added a comment - Submitting patch that seems to help
        Hide
        jbonofre Jean-Baptiste Onofré added a comment -

        I updated the patch to use SLF4J styled logging.

        Revision 1164362.

        Show
        jbonofre Jean-Baptiste Onofré added a comment - I updated the patch to use SLF4J styled logging. Revision 1164362.

          People

          • Assignee:
            jbonofre Jean-Baptiste Onofré
            Reporter:
            nickolay_martinov Nikolay Martynov
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development