holunda-io / camunda-bpm-spring-boot-deployment

Deploy multi tenant bpmn and dmn in your SpringBoot application

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Camunda BPM SpringBoot Deployment

stable Camunda 7.20 Build Status sponsored Maven Central Compatible with: Camunda Platform 7

What is it good for?

This library offers an alternative way to deploy processes and decisions (and even cases) to Camunda BPM and replaces the default Camunda auto deployment mechanism.

Why would you want to do that? There are mainly two reasons:

  • Camunda's auto deployment cannot handle multi tenant deployments within SpringBoot applications, as it does not properly discover the resources within the repackaged JAR
  • The default way to specify process archives in processes.xml is not as easy and SpringBoot-like as defining it in YAML (which this library allows)

If you want to know more about the issue with SpringBoot, you can read this article on medium.

How to use the library

Setup

Add the dependency to your pom.xml:

<dependency>
  <groupId>io.holunda.deployment</groupId>
  <artifactId>camunda-bpm-spring-boot-deployment</artifactId>
  <version>1.20.0</version>
</dependency>

If you are using Gradle Kotlin DSL add to your build.gradle.kts:

implementation("io.holunda.deployment:camunda-bpm-spring-boot-deployment:1.20.0")

For Gradle Groovy DSL add to your build.gradle:

implementation 'io.holunda.deployment:camunda-bpm-spring-boot-deployment:1.20.0'

The library configures itself by Spring Autoconfiguration and is enabled by default, if necessary you can still disable the deployment mechanism by adding the following property to your application.yaml:

camunda:
  bpm:
    deployment:
      enabled: false

NB! Make sure you disable Camunda's auto deployment! It is as easy as just deleting the processes.xml.

Configuration

Instead of processes.xml you now have configure the process archives in your application.yaml:

camunda:
  bpm:
    deployment:
      archives:
        - name: Default
          path: tenants/default
        - name: TenantOne
          tenant: one
          path: tenants/one

If you don't specify a tenant, the tenant within Camunda will be null, which is the Camunda default.

You have to place your resources in a folder structure that matches the specified archives:

src/main/resources
  /tenants
    /default
      - firstProcess.bpmn
    /one
      - secondProcess.bpmn

License

Apache License 2

This library is developed under Apache 2.0 License.

Contribution

If you want to contribute to this project, feel free to do so. Start with Contributing guide.

Maintainer

stefanzilske jangalinski zambrovski
stefanzilske jangalinski zambrovski

About

Deploy multi tenant bpmn and dmn in your SpringBoot application

License:Apache License 2.0


Languages

Language:Kotlin 100.0%