flow expressions

Flow expressions are the building blocks of process definitions.

basic expressions

  • cancel_process – cancelling (aborting) a whole process instance
  • concurrence – parallel orchestration
  • concurrent_iterator – a bit like a parallel ‘for’
  • cursor – a sequence, but with rewind / jump / exit …
  • loop/repeat – a cursor, with an implicit rewind
  • define – used to define a process or a subprocess
  • equals – comparing values (used with ‘if’)
  • if – ‘if’ branching
  • iterator – iterating over a list of value (a classic, sequential ‘for’)
  • noop – no-operation expression
  • participant – hands a workitem to a[n external] participant
  • sequence – serial orchestration
  • set – sets a process variable or a workitem field
  • subprocess – invokes (launches) a subprocess definition
  • wait – waits (sleeps) for a given amount of time

advanced expressions

  • add_branches – adds new branches to a running ‘concurrent_iterator’
  • apply – used to leverage a segment of process passed to a subprocess (like block/yield in Ruby)
  • await – a successor to listen, an attempt to a better syntax
  • cancel – an alias for the ‘undo’ expression
  • cron / every – executes pieces of a process at given intervals
  • error – forces the process instance into error
  • filter – performs filtering on the passing workitem
  • inc / dec – {inc|dec}rementing variables or fields (numbers or arrays)
  • listen – listen to workflow events (reaching or leaving participants or tags, or errors) and react (ruote 2.3.0 brings await with a potentially better syntax)
  • read – reads the content of a file (URI) and places it in a workitem field or process variable
  • redo – redoes a tagged segment of process
  • ref – invokes a participant or a subprocess indifferently
  • registerp – registers participants from a process definition
  • reserve – ensures a segment of process instance is traversed in isolation (not in parallel with other branches of the same instance)
  • restore – restores values from a previously saved workitem
  • save – saves the current workitem
  • undo – undoes a tagged segment of process
  • on_error – (from ruote 2.3.0 on) when the :on_error attribute is not sufficient, finer grained error handling
  • once – (‘when’ alias) waits for a condition to become true before triggering
  • let – a sequence but with a dedicated variable scope
  • given and that/of – a case/switch statement equivalent
  • read – reads a file (local or over http) and places its content in a field or a variable

other expressions

Expressions used in debug time or that have become slightly obsolete

  • echo – echoes some text to stdout (debug only)
  • forget – forgets a segment of process (supplanted by the :forget attribute common to all expressions)
  • lose – triggers its children, but never replied to its parent expression

attributes common to all expressions

There is a set of attributes common to all expressions, it includes :if, :unless, :timeout, :on_error, :on_cancel, :on_timeout, :lose and :forget

dollar notation : variable/fields extrapolation

The dollar notation is used in expression attributes to enhance process definitions.

            participant :ref => '${field:author}'
              # the actual name of the participant is held in the workitem field 'author'