Uploaded image for project: 'camunda BPM'
  1. camunda BPM
  2. CAM-9381

Calling correlate all in the same transaction twice should not lead to an exception

    Details

      Description

      Using the correlateAll[WithResult] API with the same correlation in a single transaction raises an exception.

      runtimeService.createMessageCorrelation("waitForCorrelationKeyMessage")
          .setVariables(variablesFistCall)
          .processInstanceVariableEquals("correlationKey", "someCorrelationKey")
          .correlateAllWithResult();
      
      org.camunda.bpm.engine.ProcessEngineException: Execution with id '109' does not have a subscription to a message event with name 'waitForCorrelationKeyMessage': eventSubscriptions is empty
      

      The reason for this is that the second correlate call still finds the execution matching the correlation in the database but not the event subscription inside the cache as it was already removed by the first correlation call.

      We would expect that the first correlation call triggers the correlation and the second one returns with an empty result without raising an error.

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            nikola.koevski Nikola Koevski
            Reporter:
            sebastian.menski Sebastian Menski
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development