Correlation problem in POST call

Hello guys,

we are facing strange problem with a message correlation.

Tomcat
BPM v7.12.1-ee
MS SQL

CorrelationIssue.bpmn (8.8 KB)

Task “Start B” in Process A starts Process B using runtime service which returns the process instance ID of process B
processBId = runtimeService.startProcessInstanceByKey(“ProcessB”, variables).getId()
The task “Start B” does not have a async flag.
That part works fine.

Task “Call SB1” performs a POST call to engine using following correlation:

{
“messageName” : “SB1_start”,
“processInstanceId” : processBId
}

The POST call fails with Response code 400 (correlation failed).

Process B does not have any async flag in the start event.

Event Sub-Process SB1 does not have any async flag in the message start event.

Any idea why the correlation fails?

Engine does not give any exception.

Same call using POSTMAN is working fine.

Thanks for your support.

Is process B actually deploying the pool is not marked executable.
Also - why are you correlating on the processing instance Id, this generally isn’t a good idea - try to use a business key instead and/or some correlation keys

Thanks Niall for your reply, the uploaded process just shows the essential problem of a more complex process. The one shared was not deployed.
The start event of the eventbased sub-process is supposed to be non-interrupting.
We will however try to use business key for correlation instead.

Meanwhile a check using the business key for the correlation gave same problem.

org.camunda.commons.logging.BaseLogger.logError ENGINE-16004 Exception while closing command context: Cannot correlate message ‘Msg_Rec_Process_B’: No process definition or execution matches the parameters
org.camunda.bpm.engine.MismatchingMessageCorrelationException: Cannot correlate message ‘Msg_Rec_Process_B’: No process definition or execution matches the parameters

Cheers,
Ingo

The problem could be solved by marking the 2nd call “Async before”.