I have the below event-driven architecture in a distributed environment where I’m sending a command to get user payment details (Query) from the user service and in the next task I need to get from java code those user payment details to process payment adapter delegate.
Kindly advice how to get the Correlating Message of the user details from the process payment adapter using java code ?
Here at the company we have a Camunda project that orchestrates microservices and uses SpinJson, this is because the company people didn’t like Java and we do all the code internally within Camunda’s own tasks, without external code files.
but I particularly love Java… and if it were up to me, all my projects would be with Camunda embedded with spring / Java / JavaDelegates.
Yeah, that’s why I was asking about using the Spin plugin. If it’s because you don’t want to do Java, then that’s fine, but I think a better alternative to using Spin / scripts is then to use the external task pattern and choose a programming language that you like and which is supported by your organization.
Personally I am not a big fan of the Spin / script setup and I would also prefer a Java setup like the one William describes
Both can be used together, and serve different purposes.
For example, in a microservices orchestration project, you may need to use Spin more.
When we use external tasks, processing occurs outside the camunda engine, returning a success or failure response, serves for asynchronous processing.
Spin, on the other hand, basically works with input data processing… for example, you can access an API with an http-connector, and receive the response… from this response you can assemble payloads to pass as input data to the next microservice you will call.
But without a doubt, the fact that we can use any language with external tasks is what makes external tasks so widely used! Thank you for helping to share knowledge \o
Thank you for your input.
I agree that different styles suit different needs / preferences. I would still choose the external task pattern over Spin / script - also for microservice orchestration. But that really is more of a personal preference