lib/spring-zeebe-broker

This pom defines the required plugins and profiles to allow a camunda release build. Inherit this pom when you want to release your project into the camunda nexus and/or maven central.

License

License

Apache License
GroupId

GroupId

io.zeebe.spring
ArtifactId

ArtifactId

spring-zeebe-broker
Last Version

Last Version

0.7.0
Release Date

Release Date

Type

Type

jar
Description

Description

lib/spring-zeebe-broker
This pom defines the required plugins and profiles to allow a camunda release build. Inherit this pom when you want to release your project into the camunda nexus and/or maven central.
Project Organization

Project Organization

Camunda Services GmbH

Download spring-zeebe-broker

How to add to project

<!-- https://jarcasting.com/artifacts/io.zeebe.spring/spring-zeebe-broker/ -->
<dependency>
    <groupId>io.zeebe.spring</groupId>
    <artifactId>spring-zeebe-broker</artifactId>
    <version>0.7.0</version>
</dependency>
// https://jarcasting.com/artifacts/io.zeebe.spring/spring-zeebe-broker/
implementation 'io.zeebe.spring:spring-zeebe-broker:0.7.0'
// https://jarcasting.com/artifacts/io.zeebe.spring/spring-zeebe-broker/
implementation ("io.zeebe.spring:spring-zeebe-broker:0.7.0")
'io.zeebe.spring:spring-zeebe-broker:jar:0.7.0'
<dependency org="io.zeebe.spring" name="spring-zeebe-broker" rev="0.7.0">
  <artifact name="spring-zeebe-broker" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.zeebe.spring', module='spring-zeebe-broker', version='0.7.0')
)
libraryDependencies += "io.zeebe.spring" % "spring-zeebe-broker" % "0.7.0"
[io.zeebe.spring/spring-zeebe-broker "0.7.0"]

Dependencies

compile (3)

Group / Artifact Type Version
io.zeebe.spring : spring-zeebe-util jar 0.7.0
io.zeebe : zeebe-broker jar
org.projectlombok : lombok jar

provided (1)

Group / Artifact Type Version
org.springframework : spring-context jar

test (1)

Group / Artifact Type Version
io.zeebe.spring : spring-zeebe-test jar 0.7.0

Project Modules

There are no modules declared in this project.

Spring Zeebe

Maven Central

Build Status codecov Project Stats

This project allows to leverage Zeebe within your Spring or Spring Boot environment easily. It is basically a wrapper around the Zeebe Java Client.

How to use

Connect to Zeebe Broker

Just add the @EnableZeebeClient annotation to your Spring Boot Application:

@SpringBootApplication
@EnableZeebeClient
public class MySpringBootApplication {

Now you can inject the ZeebeClient and work with it, e.g. to create new workflow instances:

@Autowired
private ZeebeClient client;

Deploy Workflow Models

Use the @ZeebeDeployment annotation:

@SpringBootApplication
@EnableZeebeClient
@ZeebeDeployment(classPathResources = "demoProcess.bpmn")
public class MySpringBootApplication {

You can also deploy multiple files at once:

@ZeebeDeployment(classPathResources ={"demoProcess.bpmn", "demoProcess2.bpmn"})

Implement Job Worker

@ZeebeWorker(type = "foo")
public void handleJobFoo(final JobClient client, final ActivatedJob job) {
  // do whatever you need to do
  client.newCompleteCommand(job.getKey()) 
     .variables("{\"fooResult\": 1}")
     .send().join();
}

Configuring Zeebe Connection

zeebe.client.worker.defaultName=foo-worker
zeebe.client.broker.gatewayAddress=127.0.0.1:26500
zeebe.client.security.plaintext=true

If you build a worker that only serves one thing, it might also be handy to define the worker job type

zeebe.client.worker.defaultType=foo

For a full set of configuration options please see ZeebeClientConfigurationProperties.java

Configuring Camunda Cloud Connection

Connections to the Camunda Cloud can be easily configured:

zeebe.client.cloud.clusterId=xxx
zeebe.client.cloud.clientId=xxx
zeebe.client.cloud.clientSecret=xxx

If you don't connect to the Camunda Cloud production environment you might have to also adjust these two properties:

zeebe.client.cloud.baseUrl=zeebe.camunda.io
zeebe.client.cloud.port=443
zeebe.client.cloud.authUrl=https://login.cloud.camunda.io/oauth/token

As an alternative you can use the Zeebe Client environment variables.

Add Spring Boot Starter to Your Project

Just add the following Maven dependency to your Spring Boot Starter project:

<dependency>
	<groupId>io.zeebe.spring</groupId>
	<artifactId>spring-zeebe-starter</artifactId>
	<version>${CURRENT_VERSION}</version>
</dependency>

Examples

Have a look into the examples/ folder for working Maven projects that might serve as inspiration.

Code of Conduct

This project adheres to the Contributor Covenant Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to [email protected].

io.zeebe.spring
This organization contains the internal repositories of the Zeebe development team. Please visit https://github.com/camunda-cloud/zeebe for the Zeebe repository

Versions

Version
0.7.0
0.6.0
0.5.0
0.4.0
0.3.0
0.2.0
0.1.0