Issue With Spring AutoDeployment

We are having a problem deploying the camunda processes in a cluster environment (consisting of two machines) using Spring Boot AutoDeployment (processes definitions are located in the resources folder of our Spring project). The engine is deployed through a Jenkins pipeline on both machines simultaneously (both engines share the same database). We have explicitly set the deploymentLockUsed properties equal to true in our application.yml. However, two identical deployments are created having same definition version. This causes a number of problems, the most important of which is that we can’t start a process instance (the engine expects to find only one process definition but actually finds two). Are there any things we overlooked or didn’t take into consideration when using Spring? Can you give us some help? Thanks in advance for your support.

Hi,

Does anyone have any suggestions for how to avoid this issue?

Hello my friend @Dalton_Delpiano!

In your “processes.xml” file you put the tag:

<property name="isDeployChangedOnly">true</property>

This tag marked as true, serves so that when scanning the processes, it will only deploy if the processDefinition had any change… otherwise it will not create a new deploy of this process.

In below, an exemple of my processes.xml configuration:

<?xml version="1.0" encoding="UTF-8" ?>
<process-application xmlns="http://www.camunda.org/schema/1.0/ProcessApplication">
    <process-archive name="camunda-empregadores">
        <process-engine>default</process-engine>
        <properties>
            <property name="isDeleteUponUndeploy">false</property>
            <property name="isScanForProcessDefinitions">true</property>
            <property name="isDeployChangedOnly">true</property>
        </properties>
    </process-archive>
</process-application>

I hope this helps.

William Robert Alves

Taking this opportunity, I suggest not reviving such old topics, but creating a new topic, so that if your solution is found, you can mark it as solved so that other users can find the solution from the search for the resolved topic :smiley: