Camunda 7 Asynchronous Implementation

Using Camunda 7.21 remote based engine

I have the tasks in the below flow
User Task 1 → Service Task (Custom Logic for executing 30 seconds) → User Task 2
Spring Boot RestController is responsible to complete User Task 1 & same API should return the User Task 2 ID in the response of the First API call. without delaying the 30 seconds execution of the service task, How can we achieve this ?

Hi @vinothkumar
If User Task 2 is not dependent on the completion of the service task, you can utilize a fire-and-forget approach by placing the service task in a separate process and triggering it using an intermediate throw message.

image

Service Task is either implemented as an external task or async before is used

1 Like

Thanks for the quicky reply @hassang .
I will try and come back if anything required.

Hi @hassang ,
I am using below URL to trigger my workflow as I am using the start message event, But I dont see these variables are available for my processes (User Task + Service Task). Is am I missing something ? Please help here.

URL: http://localhost:8080/engine-rest/message (Post)
Request:
{
“messageName”: “trigger-email”,
“variables”: {
“router”: {
“type”: “String”,
“value”: “r1”
},
“test”: {
“type”: “String”,
“value”: “testingVariable”
}
}
}

I believe this is a different question. However, processVariables attribute should be used.

Thanks a lot @hassang . Its working fine.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.