Correlate message from one process definition to another

I have two process definitions: FIRST REVIEW and SECOND REVIEW. Both of them should have a possibility to be canceled by the user at any time, that’s why I’ve created an Event cancellation subprocess in FIRST REVIEW:

It is triggered by the Message Correlation call, this is how it looks like:

{
        messageName: 'StartCancelSubprocess',
        processInstanceId: "FIRST_REVIEW_PROCESS_INSTANCE_ID",
        processVariables: {
          cancellationType: {
            value: 'manual',
            type: 'String'
          },
          canceledBy: {
            value: 'User',
            type: 'String'
          }
        }
      }

For the FIRST REVIEW process definition, it works perfectly - it interrupts the main process flow and goes into the cancelation subprocess, where the process ends.

But if I’m trying to call the same cancelation subprocess (which is located in FIRST REVIEW diagram) from the SECOND REVIEW process definition, it throws the following error:

message: “org.camunda.bpm.engine.MismatchingMessageCorrelationException: Cannot correlate message ‘StartCancelSubprocess’: No process definition or execution matches the parameters”

Are there any solutions to how such situations may be handled? Or I need to create a similar Event cancel subprocess in the SECOND REVIEW process definition. I’ve added both diagrams as an example.

REVIEW_1.bpmn (2.7 KB) REVIEW_2.bpmn (2.7 KB)

@Leocete the bpmn models which you have attached doesn’t have proper configurations. Also, the event subprocess must contain event based start event and not the none start event.

None start events are not supported for event subprocesses.

An event subprocess may be interrupting or non-interrupting. The event subprocess is a subprocess that is triggered by an event. An event subprocess can be added at the process level or at any subprocess level. The event used to trigger an event subprocess is configured using a start event.

Refer the documentation to read more about event subprocess: