Hi folks,
I am using Camunda 7.11 with the camunda-spring-boot-starter 3.3.3 and I try to achieve tenant specific deployments, using process archives in the processes-xml, like this:
<process-application
xmlns="http://www.camunda.org/schema/1.0/ProcessApplication"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<process-archive name="All">
<process-engine>default</process-engine>
<properties>
<property name="isDeleteUponUndeploy">false</property>
<property name="isScanForProcessDefinitions">true</property>
<property name="resourceRootPath">pa:tenants/all</property>
</properties>
</process-archive>
<process-archive name="One" tenantId="1">
<process-engine>default</process-engine>
<properties>
<property name="isDeleteUponUndeploy">false</property>
<property name="isScanForProcessDefinitions">true</property>
<property name="resourceRootPath">pa:tenants/one</property>
</properties>
</process-archive>
</process-application>
My resources folder structure looks like this:
resources
META-INF
processes-xml
tenants
all
some-process.bpmn
one
another-process.bpmn
Running the app with gradle bootRun
works fine, but running it with java -jar
does not work, because the structure of the jar is different after SpringBoot has repackaged it:
BOOT-INF
classes
META-INF
processes.xml
tenants
all
some-process.bpmn
one
another-process.bpmn
When Camunda is handling the archive in ClassPathProcessApplicationScanner#handleArchive
, it comes across the BPMN files, but their file path e.g. BOOT-INF/classes/tenants/one
is not below the paResourceRootPath
, which is e.g. tenants/one
, even though I configured it as being relative to the process archive using the pa:
prefix.
Of course, I can set the path to BOOT-INF/classes/...
in the processes.xml, but running with Gradle will not work any more. How can I achieve both?
Cheers,
Stefan