Description of problem: When I do deploy or undeploy REST API operations for a deployment unit, the get request returns wrong information. Usually I get DEPLOYING status for undeploy operation and UNDEPLOYING status for deploy operation. See the output below: ******************* create start [2014-04-29 15:56:47,110] INFO - Response entity: [{"deployment-job-result":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentJobResult",{"operation":"DEPLOY" >> HERE I HAVE DEPLOY OPERATION RESPONSE <<,"deploymentUnit":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentUnit",{"groupId":"org.jboss","artifactId":"remote-file-deployment","version":"1.0-SNAPSHOT","strategy":"PER_PROCESS_INSTANCE","status":"DEPLOYING"}],"success":true,"explanation":"Deployment (deploy) job submitted successfully."}]}] [2014-04-29 15:56:47,130] INFO - Response entity: [{"deployment-unit":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentUnit",{"groupId":"org.jboss","artifactId":"remote-file-deployment","version":"1.0-SNAPSHOT","status":"UNDEPLOYING" >> FOR THE GET RESPONSE HERE I GET UNDEPLOYING STATUS <<}]}] create end [2014-04-29 15:56:47,147] INFO - Response entity: [{"deployment-unit":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentUnit",{"groupId":"org.jboss","artifactId":"remote-file-deployment","version":"1.0-SNAPSHOT","status":"UNDEPLOYING" >> FOR THE GET RESPONSE HERE I GET UNDEPLOYING STATUS <<}]}] ****************************** and here is another try ****************************** [2014-04-29 15:49:47,619] INFO - Response entity: [{"deployment-job-result":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentJobResult",{"operation":"UNDEPLOY" >> HERE I HAVE UNDEPLOY OPERATION RESPONSE << ,"deploymentUnit":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentUnit",{"groupId":"org.jboss","artifactId":"remote-file-deployment","version":"1.0-SNAPSHOT","strategy":"PER_REQUEST","status":"UNDEPLOYING"}],"success":true,"explanation":"Deployment (undeploy) job submitted successfully."}]}] [2014-04-29 15:49:47,633] INFO - Response entity: [{"deployment-unit":["org.kie.services.client.serialization.jaxb.impl.deploy.JaxbDeploymentUnit",{"groupId":"org.jboss","artifactId":"remote-file-deployment","version":"1.0-SNAPSHOT","status":"DEPLOYING" >> SEE THE GET RESPONSE HERE I GET DEPLOYING THOUGH I REQUESTED TO UNDEPLOY THE DEPLOYMENT UNIT << }]}] ******************************* Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info:
Could you add a test that reproduces this problem? Thanks!
I just realized that there might be a problem with BZ 1050894 if you work with the last changes.
Fixed with this commit: https://github.com/droolsjbpm/droolsjbpm-integration/commit/1509b17022b4141e303dd7eef396d8ebcdb27184 (Among other changes, here: https://github.com/droolsjbpm/droolsjbpm-integration/commit/1509b17022b4141e303dd7eef396d8ebcdb27184#diff-e7fb6939eaedec362d0e943f20d7b449R48 ) However, the deployment operations were somewhat refactored, so there are a couple of other changes that helped fix this as well.
Verified in BPMS 6.1.0.DR2 The current behavior is following: ACCEPTED -> UNDEPLOYING -> UNDEPLOYED ACCEPTED -> DEPLOYING -> DEPLOYED
Additionally, I filed BZ 1139745 - After undeployment of a deployment unit which was previously deployed via REST API, status of the deployment unit remains DEPLOYED instead of NONEXISTENT.