Bug 1133216 - Deployment unit does not survive server reload
Summary: Deployment unit does not survive server reload
Keywords:
Status: CLOSED EOL
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: Business Central
Version: 6.0.2
Hardware: Unspecified
OS: Unspecified
urgent
high
Target Milestone: ER4
: 6.1.0
Assignee: Marco Rietveld
QA Contact: Marek Baluch
Dawn Eisner
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-08-23 11:15 UTC by Anton Giertli
Modified: 2020-03-27 20:10 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-03-27 20:10:11 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
[0] server.log (9.76 KB, text/x-log)
2014-08-23 11:15 UTC, Anton Giertli
no flags Details
6.1 ER2 server.log (336.76 KB, text/plain)
2014-12-10 13:20 UTC, Zuzana Krejčová
no flags Details

Description Anton Giertli 2014-08-23 11:15:43 UTC
Created attachment 929864 [details]
[0] server.log

Description of problem:


If you restart bpm server via cli, using :reload command

the deployment unit does not survive.

Version-Release number of selected component (if applicable):
 bpm 6.0.2

How reproducible:
always

Steps to Reproduce:
1. Build & Deploy project
2. issue :reload command from cli
3. Go check deployments - it's empty (this is already unexpected)
4. process definitions - empty also
5. Navigate to Tools -> Project Editor, try to build the project again

It will fail with the following message:
Deployment of unit org.kie.example:project1:1.0.0-SNAPSHOT failed: java.lang.IllegalStateException: RuntimeManager with id org.kie.example:project1:1.0.0-SNAPSHOT is already active

stacktrace displayed in server.log is attached. it's pretty much the same though.

6. if you restart the server completely (ctrl+c) then everything is back to normal - the deployment will be shown under Deploy - > Deployments and you can execute Build & Deploy command without any issues.

Actual results:

Deployment units does not survive server reload via cli
Expected results:
Deployment units survive server reload via cli without any issues


Additional info:

Comment 2 Maciej Swiderski 2014-09-16 15:54:48 UTC
While working on this there seems to be a blocker from EAP side that does not allow to reload an application that includes web service inside it. To limit the need for complete kie-wb (that currently includes web service for remote interaction) you can try with the example app of BPMS that has a war file with web service. It's enough to deploy it and then on running server invoke :reload to see it failing to deploy

that effectively stops us from ensuring the reload of kie-wb can work properly

Error I have seen locally is:
17:50:52,244 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-5) MSC000001: Failed to start service jboss.deployment.unit."jboss-mortgage-demo-ws.war".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.unit."jboss-mortgage-demo-ws.war".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment "jboss-mortgage-demo-ws.war"
	at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:127) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-redhat-8]
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_45]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_45]
	at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_45]
Caused by: java.lang.IllegalStateException
	at org.jboss.msc.value.InjectedValue.getValue(InjectedValue.java:47) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
	at org.jboss.as.webservices.config.ServerConfigImpl.getServerEnvironment(ServerConfigImpl.java:80)
	at org.jboss.as.webservices.config.ServerConfigImpl.getServerDataDir(ServerConfigImpl.java:58)
	at org.jboss.wsf.stack.cxf.deployment.WSDLFilePublisher.getPublishLocation(WSDLFilePublisher.java:161)
	at org.jboss.wsf.stack.cxf.deployment.WSDLFilePublisher.publishWsdlFiles(WSDLFilePublisher.java:69)
	at org.jboss.wsf.stack.cxf.deployment.EndpointImpl.publishContractToFilesystem(EndpointImpl.java:132)
	at org.jboss.wsf.stack.cxf.deployment.EndpointImpl.doPublish(EndpointImpl.java:72)
	at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:250)
	at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:536)
	at org.jboss.wsf.stack.cxf.configuration.NonSpringBusHolder.configure(NonSpringBusHolder.java:116)
	at org.jboss.wsf.stack.cxf.deployment.aspect.BusDeploymentAspect.startDeploymentBus(BusDeploymentAspect.java:128)
	at org.jboss.wsf.stack.cxf.deployment.aspect.BusDeploymentAspect.start(BusDeploymentAspect.java:67)
	at org.jboss.as.webservices.deployers.AspectDeploymentProcessor.deploy(AspectDeploymentProcessor.java:74)
	at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:120) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-redhat-8]

Comment 5 Zuzana Krejčová 2014-12-10 13:13:33 UTC
I retested with BPMS ER2 on EAP 6.3.1. ':reload' from jboss-cli has the same effect as noted in the initial description.

Issue persists.

Comment 6 Zuzana Krejčová 2014-12-10 13:20:34 UTC
Created attachment 966797 [details]
6.1 ER2 server.log

Noteworthy bits:

When undeploying:

WARN  [org.jbpm.shared.services.impl.TransactionalCommandService] ... Could not commit session: org.hibernate.service.UnknownServiceException: Unknown service requested [org.hibernate.service.jdbc.connections.spi.ConnectionProvider]
...
WARN  [org.jbpm.executor.impl.AvailableJobsExecutor] ... Unexpected error while processin executor's job Unknown service requested [org.hibernate.service.jdbc.connections.spi.ConnectionProvider]: org.hibernate.service.UnknownServiceException: Unknown service requested [org.hibernate.service.jdbc.connections.spi.ConnectionProvider]
...
ERROR [org.uberfire.commons.async.SimpleAsyncExecutorService] ... Thread pool did not terminate.

While redeploying:

WARN  [org.kie.remote.services.cdi.DeploymentInfoBean] ... RuntimeManager for domain org.jbpm:Evaluation:1.0  does not exist and can not be undeployed.
ERROR [org.kie.remote.services.rest.jaxb.DynamicJaxbContext] ... JAXB context instance could not be found when undeploying deployment 'org.jbpm:Evaluation:1.0'!
INFO  [org.jbpm.kie.services.impl.store.DeploymentSynchronizer] ... Deployment unit org.jbpm:Evaluation:1.0 removed successfully
WARN  [org.jbpm.kie.services.impl.KModuleDeploymentService] ... Unexpected error while deploying unit org.jbpm:Evaluation:1.0: java.lang.RuntimeException: java.lang.IllegalStateException: RuntimeManager with id org.jbpm:Evaluation:1.0 is already active
WARN  [org.kie.remote.services.cdi.DeploymentInfoBean] ... RuntimeManager for domain org.guvnor:guvnor-asset-mgmt-project:6.2.0.redhat-1  does not exist and can not be undeployed.

Comment 7 Maciej Swiderski 2014-12-10 13:34:19 UTC
looks like this commit is missing in the build you're testing on:
https://github.com/droolsjbpm/jbpm-console-ng/commit/6ec931ea21d44a40c7d0b1935a2b838cd414846c

is that correct? If so then it might be needed to retest it once it's in. I just did test locally and that worked ok with reload.

Do you mind verifying if that commit is present or not?

Comment 8 Zuzana Krejčová 2014-12-11 09:18:32 UTC
(In reply to Maciej Swiderski from comment #7)
> looks like this commit is missing in the build you're testing on:
> https://github.com/droolsjbpm/jbpm-console-ng/commit/
> 6ec931ea21d44a40c7d0b1935a2b838cd414846c
> 
> is that correct? If so then it might be needed to retest it once it's in. I
> just did test locally and that worked ok with reload.
> 
> Do you mind verifying if that commit is present or not?

This commit is not present in ER2.

The latest commit in that project (in this build's tag) seems to be from Fri, 7 Nov 2014. Commit 6ec931 isn't there. 
The jbpm-console-ng-business-domain-backend jar in the b.-c. lib dir contains at the very least DeploymentManagerEntryPointImpl class without the change, as far as I can tell.

Comment 9 Kris Verlaenen 2015-01-14 14:38:02 UTC
https://github.com/droolsjbpm/jbpm-console-ng/commit/6ec931ea21d44a40c7d0b1935a2b838cd414846c was applied to 6.2.x on Nov 20th 2014, so should be in the latest tag now.

Comment 10 Maciej Swiderski 2015-01-14 14:40:09 UTC
I have one more fix for it when running with JBoss Modules and will push it soon - running tests now.

Comment 11 Maciej Swiderski 2015-01-14 16:23:34 UTC
additional fix provided to ensure it will work well with modules version of kie-wb application

jbpm
master:
https://github.com/droolsjbpm/jbpm/commit/a8fdcd91d979528ea862bbd82f7391a0b2d5b74c

6.2.x:
https://github.com/droolsjbpm/jbpm/commit/7d454c2f850a17dcc71a0b81e3491d5fa7d369bd

Comment 12 Jiri Svitak 2015-01-28 11:31:27 UTC
Verified in BPM Suite 6.1.0.ER4.


Note You need to log in before you can comment on or make changes to this bug.