Uploaded image for project: 'Kogito'
  1. Kogito
  2. KOGITO-9785

Workflow and State timeout support for Error Handling

XMLWordPrintable

      It should be possible to trigger a timeout that runs a branch not interrupting the node it is attached to. This is useful to implement escalation where we want to trigger some workflow or external service if the timeout is expired but not continuing the flow execution.

       

      Notes:
      For escalations, this will require an extension to the SW spec, have an additional attribute somehow that defines if the timeout should be interrupting or not. Then the generated core workflow model should either just branch or use this event-based split like it is doing now:
      https://github.com/kiegroup/kogito-runtimes/blob/main/kogito-serverless-workflow/kogito-serverless-workflow-builder/src/main/java/org/kie/kogito/serverless/workflow/parser/handlers/StateHandler.java#L483C45-L483C64

      yes makes sense, we need a new property, because right now on the timeout we interrupt and move and continue the flow, and the only way to know a timeout was triggered is to check the output parameters if we want to trigger a timeout and stay in the node, we need an extra property and we need a way to map the timeout to an state, so 2 branches outgoing the node
      It seems for workflow timeouts they have this interrupt property already, just not for states
      The timeout is already implemented as a timer node on a parallel path, so you just need a normal parallel gateway before and no merging gateway after in case of non-interrupting
       
       

              ftirados Francisco Javier Tirado Sarti
              tdolphin-1 Tiago Dolphine (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: