Zeebe client and JobWorker design patterns

Hello,

While working on a Zeebe POC, I have:

  • started Zeebe with docker-compose,
  • deployed a workflow from the command line,
  • joined JobWorkers to the broker with spring-zeebe spring-boot
  • and created a workflow instance with a rest service call to a service that starts the workflow.

Some questions in mind:

  • Bernt Ruecker’s (and others’) spring-zeebe example puts all the workers into one spring-boot project/jar. It is impossible to generalise, but is this the recommended way, or is this for demo purposes?
  • How about deploying the workflows and creating the instances. These too are often in the same project/jar together with the workers. I assume that this too is for demo purposes. Or is it really recommended to deploy a workflow and create an instance at the same time as creating and joining the workers to the broker?
  • Scaling the broker is discussed in several places. How about scaling JobWorkers? Do you have any thoughts about that?

The example given only for demo purpose, you can create workers in multiple spring-boot applications

` How about deploying the workflows and creating the instances. These too are often in the same project/jar together with the workers. I assume that this too is for demo purposes. Or is it really recommended to deploy a workflow and create an instance at the same time as creating and joining the workers to the broker?

its recommended to deploy workflow and create an instance by using the process id. if your using @EnableZeebeDeployment annotation then it will deploy the workflow only once untill you change the workflow defination and you can create instances using the process id

  • Scaling the broker is discussed in several places. How about scaling JobWorkers? Do you have any thoughts about that?

You can able to scale the job workers, if your using the spring zeebe then below is the annotation attribute to set the max active job
@ZeebeWorker(maxJobsActive = 5,name = “xxx”,type = “xxdd”)

1 Like

Hi,
Thank you for the input.