I'm trying to use the RepositoryService to undeploy a process definition in Java code. To do this I:
1) Find the process definition's deployment ID
2) Call repositoryService.deleteDeployment(deploymentId);
The problem is, is that this deletes almost all of the process definitions I have (except for one). The way I load process definitions upon startup of the server is through my ProcessApplication (i.e. processes.xml and isScanForProcessDefinitions=true).
Three questions:
1) Is it expected to have multiple process definitions with the same deployment ID?
2) Why does only one out my 17 process definitions get a different ID? (all my process definitions are in the same directory in my ProcessApplication)
3) Is there a way to delete a particular process definition in my case (for example by procDef key instead of deployment ID)?
++++++++++++++++++++++++++++++
HERE IS MY DATABASE TABLE:
mysql> select DEPLOYMENT_ID_, count(*) from act_re_procdef group by DEPLOYMENT_ID_;
+--------------------------------------+----------+
| DEPLOYMENT_ID_ | count(*) |
+--------------------------------------+----------+
| 60b0ced6-9fd4-11e3-95e0-10ddb1f141ab | 16 |
| d181094b-9fd2-11e3-8b0e-10ddb1f141ab | 1 |
+--------------------------------------+----------+
2 rows in set (0.00 sec)
Thanks,
Galen
I'm mostly concerned about my question #3 (see above) about deleting a particular process definition. Any clarification or guidance on how to do this would be great. Also, if not available, is this functionality on the roadmap?
Thanks,
Galen
Does the repositoryService.deleteDeployment method also have the same issue of redployment/restart? I'm assuming it would.
The more I think about it, for my purposes, I would probably be OK with simply suspending the process definition, instead of having to remove it completely. So I probably don't need to create an issue. I haven't tried it yet, but I'm assuming the process definition will remain suspended when a redployment/restart occurs.
Thanks for your input,
Galen