Uploaded image for project: 'camunda BPM'
  1. camunda BPM
  2. CAM-10231

Camunda sometimes fails to shut down with NoClassDefFoundError

    • Icon: Bug Report Bug Report
    • Resolution: Cannot Reproduce
    • Icon: L3 - Default L3 - Default
    • None
    • 7.10.0
    • webapp
    • None
    • Debian GNU/Linux 9 on Intel x64, Oracle Java build 1.8.0_201-b09

      when I run the Tomcat shutdown script, Camunda sometimes shuts down as expected and sometimes logs the following message:

      30-Apr-2019 15:30:10.349 SEVERE [main] org.apache.catalina.startup.Catalina.stop Catalina.stop
      org.apache.catalina.LifecycleException: Failed to stop component [StandardServer[8005]]
      at org.apache.catalina.util.LifecycleBase.handleSubClassException(LifecycleBase.java:441)
      at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:267)
      at org.apache.catalina.startup.Catalina.stop(Catalina.java:755)
      at org.apache.catalina.startup.Catalina.start(Catalina.java:717)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:498)
      at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:350)
      at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:492)
      Caused by: java.lang.NoClassDefFoundError: org/camunda/bpm/engine/impl/SchemaOperationProcessEngineClose
      at org.camunda.bpm.engine.impl.ProcessEngineImpl.close(ProcessEngineImpl.java:143)
      at org.camunda.bpm.container.impl.jmx.services.JmxManagedProcessEngineController.stop(JmxManagedProcessEngineController.java:41)
      at org.camunda.bpm.container.impl.jmx.MBeanServiceContainer.stopService(MBeanServiceContainer.java:124)
      at org.camunda.bpm.container.impl.deployment.StopProcessEnginesStep.stopProcessEngine(StopProcessEnginesStep.java:58)
      at org.camunda.bpm.container.impl.deployment.StopProcessEnginesStep.performOperationStep(StopProcessEnginesStep.java:46)
      at org.camunda.bpm.container.impl.spi.DeploymentOperation.execute(DeploymentOperation.java:119)
      at org.camunda.bpm.container.impl.jmx.MBeanServiceContainer.executeDeploymentOperation(MBeanServiceContainer.java:159)
      at org.camunda.bpm.container.impl.spi.DeploymentOperation$DeploymentOperationBuilder.execute(DeploymentOperation.java:215)
      at org.camunda.bpm.container.impl.tomcat.TomcatBpmPlatformBootstrap.undeployBpmPlatform(TomcatBpmPlatformBootstrap.java:100)
      at org.camunda.bpm.container.impl.tomcat.TomcatBpmPlatformBootstrap.lifecycleEvent(TomcatBpmPlatformBootstrap.java:65)
      at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:123)
      at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:424)
      at org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:367)
      at org.apache.catalina.core.StandardServer.stopInternal(StandardServer.java:786)
      at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:257)
      ... 8 more
      Caused by: java.lang.ClassNotFoundException: org.camunda.bpm.engine.impl.SchemaOperationProcessEngineClose
      at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:424)

        This is the controller panel for Smart Panels app

          1. bpm-platform.xml
            4 kB
          2. catalina.2019-04-26.log
            2.08 MB
          3. server.xml
            8 kB
          4. shutdown.sh
            2 kB

            [CAM-10231] Camunda sometimes fails to shut down with NoClassDefFoundError

            David Hodges created issue -
            Yana Vasileva made changes -
            Assignee New: Yana Vasileva [ yana.vasileva ]

            Hi DavidHodges,

            Thanks for reaching out to us with this.
            What is the database schema update configuration of your engine?

            Best regards,
            Yana

            Yana Vasileva added a comment - Hi DavidHodges , Thanks for reaching out to us with this. What is the database schema update configuration of your engine? Best regards, Yana

            David Hodges added a comment -

            I'm not sure where to find that but it's using the default configuration (H2 database) - I haven't changed it.

            David Hodges added a comment - I'm not sure where to find that but it's using the default configuration (H2 database) - I haven't changed it.

            Could you please confirm what is your setup - do you use the pre-packaged Tomcat distribution?
            Which Camunda version do you use, is it 7.10.0 as it is stated in the ticket?
            With "Tomcat shutdown script", are you refer to shutdown-camunda.sh file (included in the last 7.11.0-alpha3 Camunda release) or something else?

            Yana Vasileva added a comment - Could you please confirm what is your setup - do you use the pre-packaged Tomcat distribution? Which Camunda version do you use, is it 7.10.0 as it is stated in the ticket? With "Tomcat shutdown script", are you refer to shutdown-camunda.sh file (included in the last 7.11.0-alpha3 Camunda release) or something else?

            David Hodges added a comment -

            Yes, I am using the pre-packaged Tomcat distribution bundled with Camunda.
            Yes, it is Camunda 7.10.0
            Yes I am referring to the included shutdown-camunda.sh script.

            David Hodges added a comment - Yes, I am using the pre-packaged Tomcat distribution bundled with Camunda. Yes, it is Camunda 7.10.0 Yes I am referring to the included shutdown-camunda.sh script.

            I checked that we don't ship the shutdown-camunda.sh script with 7.10.0, from where did you take it?
            I tried the script on 7.11.0-alpha3 and it works as expected (the result on 7.10.0 was the same).
            Could you please upload the complete server log file when the issue occurred.
            Do you have any changes on the process engine configuration or it is the default one (shipped in the pre-packaged Tomcat distribution)?
            Does this exception occur also when you just terminate the java process of the Tomcat?

            Yana Vasileva added a comment - I checked that we don't ship the shutdown-camunda.sh script with 7.10.0, from where did you take it? I tried the script on 7.11.0-alpha3 and it works as expected (the result on 7.10.0 was the same). Could you please upload the complete server log file when the issue occurred. Do you have any changes on the process engine configuration or it is the default one (shipped in the pre-packaged Tomcat distribution)? Does this exception occur also when you just terminate the java process of the Tomcat?
            David Hodges made changes -
            Attachment New: catalina.2019-04-26.log [ 28538 ]
            David Hodges made changes -
            Attachment New: server.xml [ 28540 ]

            David Hodges added a comment -

            the shutdown script is in the file camunda-bpm-tomcat-7.10.0.tar.gz which I'm pretty sure I downloaded from the camunda website:
            rwxr-x-- 0/0 1902 2018-09-05 00:14 server/apache-tomcat-9.0.12/bin/shutdown.sh

            The error doesn't occur every time. Looking back at the log files I see it happened 4 times out of 106 shutdowns.
            It has also failed to find two other classes during shutdown, as you can see from the attached log file.
            I don't think I have seen this exception occur when I just terminate the java process.
            There is a one line addition to server.xml to enable logback logging, also uploaded.

            David Hodges added a comment - the shutdown script is in the file camunda-bpm-tomcat-7.10.0.tar.gz which I'm pretty sure I downloaded from the camunda website: rwxr-x -- 0/0 1902 2018-09-05 00:14 server/apache-tomcat-9.0.12/bin/shutdown.sh The error doesn't occur every time. Looking back at the log files I see it happened 4 times out of 106 shutdowns. It has also failed to find two other classes during shutdown, as you can see from the attached log file. I don't think I have seen this exception occur when I just terminate the java process. There is a one line addition to server.xml to enable logback logging, also uploaded.

              yana.vasileva Yana Vasileva
              DavidHodges David Hodges
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: