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

Failed jobs prevent other jobs in same instance from being executed

    XMLWordPrintable

    Details

      Description

      Scenario:

      1. BPMN process with
        1. Task A: async continuation that uses a custom retry cycle or interval
        2. Task B: async continuation
        3. Both async continuations are exclusive
      2. Process instance reaches task A; job 1 is created and fails; retry time cycle is applied
      3. While Job 1 is failed, process instance reaches task B (e.g. via process instances modification; user task completion; ...), creates job 2

      Current behavior:

      • Job 2 is only executed once job 1's retry timeout has expired

      Expected behavior:

      • Job 2 is immediately executed after creation

      Root cause:

      • When a job with a custom retry time cycle fails, it remains locked (i.e. lock owner and lock expiration time are set)
      • In particular, the retry timeout is stored as the lock expiration timeout
      • In consequence, the job executor will not acquire any other jobs of that process instance, because it thinks that the locked job is still executed

      Proposed Fix:

      • The command that applies the retry time cycle should unlock the job and set the timeout as the job's duedate

      Hint:

      • The lock owner is not set to null when the retry time cycle is applied, see DefaultJobRetryCmd

        mgm-controller-panel

        This is the controller panel for Smart Panels app

          Attachments

            Activity

              People

              Assignee:
              nikola.koevski Nikola Koevski
              Reporter:
              thorben.lindhauer Thorben Lindhauer
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Salesforce