Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1108472

Summary: BPMS on Tomcat (EWS 2.0.1) doesn't shutdown with shutdown.sh
Product: [Retired] JBoss BPMS Platform 6 Reporter: Toshiya Kobayashi <tkobayas>
Component: Business CentralAssignee: Alexandre Porcelli <porcelli>
Status: CLOSED EOL QA Contact: Marián Macik <mmacik>
Severity: high Docs Contact:
Priority: high    
Version: 6.0.1CC: kverlaen, manstis, mbaluch, mwinkler
Target Milestone: ER4   
Target Release: 6.1.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-03-27 20:07:16 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
stack-after-shutdown.log none

Description Toshiya Kobayashi 2014-06-12 06:10:21 UTC
Description of problem:

After you deploy business-central and dashbuilder in Tomcat (EWS 2.0.1) following our document (http://documentation-devel.engineering.redhat.com/site/documentation/en-US/Red_Hat_JBoss_BPM_Suite/6.0/html-single/Installation_Guide/index.html#sect-Installing_the_generic_deployable_package), you can start the Tomcat with startup.sh and use business-central and dashbuilder. But when you execute shutdown.sh, the java process is still alive.

Steps to Reproduce:

I have uploaded installed one for your convenience.
https://mocha.nrt.redhat.com/dav-readonly/temp/tkobayas/reproducer/bpms601-ews201.zip (internal)

To login business-central,

user:bpmsadmin
pass:P@ssw0rd

But actually the issue is reproducible without logging in.

- bin/startup.sh
- Observe logs/catalina.out until you see log like

Jun 09, 2014 11:44:20 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 32932 ms

- bin/shutdown.sh
- You will see logs like

Jun 09, 2014 11:44:46 AM org.apache.catalina.core.StandardServer await
INFO: A valid shutdown command was received via the shutdown port. Stopping the Server instance.
Jun 09, 2014 11:44:46 AM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["http-apr-8080"]
Jun 09, 2014 11:44:46 AM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["ajp-apr-8009"]
Jun 09, 2014 11:44:46 AM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service Catalina
Jun 09, 2014 11:44:47 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/business-central] appears to have started a thread named [pool-5-thread-1] but has failed to stop it. This is very likely to create a memory leak.
Jun 09, 2014 11:44:47 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/business-central] appears to have started a thread named [pool-8-thread-1] but has failed to stop it. This is very likely to create a memory leak.
Jun 09, 2014 11:44:47 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/business-central] appears to have started a thread named [com.google.inject.internal.util.$Finalizer] but has failed to stop it. This is very likely to create a memory leak.
Jun 09, 2014 11:44:47 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/business-central] appears to have started a thread named [Thread-7] but has failed to stop it. This is very likely to create a memory leak.
Jun 09, 2014 11:44:47 AM bitronix.tm.integration.tomcat55.BTMLifecycleListener lifecycleEvent
INFO: Shutting down Bitronix Transaction Manager
Jun 09, 2014 11:44:47 AM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["http-apr-8080"]
Jun 09, 2014 11:44:47 AM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["ajp-apr-8009"]
Jun 09, 2014 11:44:47 AM bitronix.tm.integration.tomcat55.BTMLifecycleListener lifecycleEvent
INFO: Shutting down Bitronix Transaction Manager
Jun 09, 2014 11:44:48 AM org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["http-apr-8080"]
Jun 09, 2014 11:44:48 AM org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["ajp-apr-8009"]

Actual results:

The java process is still alive (with jstack, you can observe some threads alive).

Expected results:

The java process finishes.

Comment 1 Toshiya Kobayashi 2014-06-12 07:05:45 UTC
Created attachment 907964 [details]
stack-after-shutdown.log

Comment 2 Toshiya Kobayashi 2014-06-12 07:07:49 UTC
I attached stack-after-shutdown.log which was captured with jstack after executing shutdown.sh + some while.

Comment 4 Alexandre Porcelli 2014-06-16 16:06:53 UTC
General cleanup of our shutdown:

uberfire:
(master) http://github.com/uberfire/uberfire/commit/517d92e2f
guvnor:
(6.1.x) http://github.com/droolsjbpm/guvnor/commit/c9b970352
(master) http://github.com/droolsjbpm/guvnor/commit/6a863f37a

But Errai still hanging on: https://issues.jboss.org/browse/ERRAI-764

Note: Errai doesn't have plans to have another 2.4.x release... so this bug may need to wait for next major release (6.1.x) in order to be fixed.

Comment 5 Alexandre Porcelli 2014-12-29 21:08:58 UTC
Shutdown works as expected on 6.1.x

Comment 6 Marián Macik 2015-02-10 17:11:06 UTC
I can confirm that shutdown works on 6.1.0.ER4 with EWS 2.0.1. Marking as verified.