Avoid versioning for every process in process archive

Hi everyone,

we are using the camunda-spring-boot-starter to deploy a process application containing multiple process definitions. This leads to the following behaviour: Everytime we deploy a changed process every process gets a new version (i remember reading an article about the decision behind that once but i cant’t find it anymore). Since this leads to operations hell when using the cockpit we want to avoid that every process gets a new version but just the changed process.

What we tried is setting <property name="isScanForProcessDefinitions">false</property> in the processes.xml and just referencing the processes we want to deploy with the current release via <resource></resource>.
But when we do that the process application only gets registered with the deployment for the given resources/definitions.

This again leads to problems when we need to access the application info for a given definition (registered with an old deployment). E.g. for retrieving the context path:

String deploymentId = processEngine.getRepositoryService().getProcessDefinition(processDefinitionId).getDeploymentId();
		String processApplicationName = processEngine.getManagementService().getProcessApplicationForDeployment(deploymentId);
		ProcessApplicationService processApplicationService = BpmPlatform.getProcessApplicationService();
		ProcessApplicationInfo processApplicationInfo = processApplicationService.getProcessApplicationInfo(processApplicationName);
		if(processApplicationInfo == null){
			return "";
		return processApplicationInfo.getProperties().get(ProcessApplicationInfo.PROP_SERVLET_CONTEXT_PATH);

So what I am trying to ask is this:

  1. What is the “right” way to avoid versioning all process defintions if only one has changed ? Do we need to define a ProcessApplication class for every process ? (I guess this means we either can’t use the SpringBootProcessApplication any more or have to deploy an jar for any process)
  2. Retrieving the contextPath is the only spot where we rely on the ProcessApplication-Deployment-Registration. So is it even a problem when this doesn’t exist ? While playing around with deployments i also figured out that the spring autodeploy feature doesn’t register the application with the deployment. Does that lead to any other problems ?

One last note: We already have an automated version migration on @PostDeploy in place but i don’t want to use it to overcome this issue. Doing this as a default for every process to avoid running instances in multiple versions will make it an unconcius step and thus very likely lead to errors.

Thanks in advance for help,

Hi Jan,

try isDeployChangedOnly in the processes.xml: https://docs.camunda.org/manual/7.5/reference/deployment-descriptors/tags/process-archive/#configuration-properties.

Hope this helps, Ingo

1 Like

That was exactly what i was looking for. Only the changed definition gets deployed and versioned but still all other definitions are registered with the deployment. Thanks you very much.