Correctly design job's handler

Hello!

If microservice presented as set of rest services, it usually designed as set of general methods for specific domain.
E.g myApp/users?lastName=smith will return full json object with user info.

Should we use same strategy with Zeebe?
Or Zeebe handler should use process specific methods?
E.g UserService with method/handler createHelloMessagePersonInfo wich will return {userName, userLastName}.

Thank you!

Can you please elaborate your question?
It is not clear what UserService is… you can create any wrapper on top of the Zeebe Client for your domain specific interfaces, and then deal with the data as better fit for your use case. There is nothing in Zeebe pushing you in a way or the other.

Microservices must have weak connectivity.
Isn’t such inner services interaction, when each job handler return only specific data part, makes them connectivity more strong?

I am not following you… Jobs will get the data that is propagated from the instance context. They can use any data that they want from there. On the APIs side there is no restriction on how you can encapsulate the Zeebe Client for performing commands (starting instances, sending messages) or the workers.

1 Like

I understand you, thanks!