Flow Control
Flow order control.
Available actions:
sequence (sync) - execute sub-flows in a sequence
parallel (async) - execute sub-flows in parallel
attachment - execute flow described in different file / url
repeat - repeat action multiple times
retry - repeat action till it succeeds or fails maximum number of times
for each of - execute action for each item in the array
while - execute action while condition satisfies
switch (conditional) - execute different actions based on the value
try-catch-finally - "try / catch / finally"
sleep - sleep for given amount of second
template - execute action described in template string
virtual - create virtual action handler
error - rise error
echo - print message to stdout
void - does nothing
Action Handler: Sequential steps execution
Run steps one by one, if any of steps fail - chain of execution will stop on it.
Note: parameters for each action will be cloned. Meaning each action will start its own branch unless shareParameters option is used.
ID: com.fireblink.fbl.flow.sequence
Aliases:
fbl.flow.sequenceflow.sequencesequencesync--
Example 1: Base Declaration
Example 2: Detailed Declaration
Warning: shareParameters usage is considered an anti-pattern
Action Handler: Parallel steps execution
Run all steps in parallel. If any of steps will fail - it will not affect others. However parallel step itself will be marked as failed.
ID: com.fireblink.fbl.flow.parallel
Aliases:
fbl.flow.parallelflow.parallelparallelasync||
Example 1: Base syntax
Example 2: Alternative syntax
Action Handler: Attached flow
Allows to reference external flow by its pass. Helps to logically split big flows for better organized structure.
ID: com.fireblink.fbl.flow.attachment
Aliases:
fbl.flow.attachmentflow.attachmentattachment@
Example 1: Specify flow file
Example 2: Specify directory
Example 3: Specify url to download a package
Example 4: Specify target inside the package
Example 5: Custom HTTP headers
Action Handler: Repeat flow
Repeat action multiple times.
ID: com.fireblink.fbl.flow.repeat
Aliases:
fbl.flow.repeatflow.repeatrepeat
Example:
Action Handler: Retry flow
Retry action multiple times till it passes or reach max failure attempts.
ID: com.fireblink.fbl.flow.retry
Aliases:
fbl.flow.retryflow.retryretry
Example:
Action Handler: For Each
Allows to execute action for every item in the array or key of an object.
ID: com.fireblink.fbl.flow.foreach
Aliases:
fbl.flow.foreachflow.foreachforeacheach
Example: Array
Example: Object
Action Handler: Switch flow
Allows to run action based on some condition
ID: com.fireblink.fbl.flow.switch
Aliases:
fbl.flow.switchflow.switchswitchif?
Example:
Action Handler: While
Runs action till condition is successful or not (based on configuration).
ID: com.fireblink.fbl.flow.while
Aliases:
fbl.flow.whileflow.whilewhile
Example: Positive condition check
Example: Negative condition check
Action Handler: Sleep
Sleep for a given amount of seconds.
ID: com.fireblink.fbl.flow.sleep
Aliases:
fbl.flow.sleepflow.sleepsleep
Example:
Action Handler: Try - Catch - Finally Flow
Allows to run sub-step in isolation causing its failure to be ignored by parent step. Optionally catch and finally steps can be invoked.
If catch or finally step block will be failed - this step will also be marked as failed even try block passes successfully.
ID: com.fireblink.fbl.flow.try
Aliases:
fbl.flow.tryflow.trytry
Example:
Action Handler: Template
Run action based on dynamically constructed template. This is handy as you generally can not dynamically construct YAML with EJS template inside most of the actions.
E.g: following is invalid:
It will fail as upon processing everything that goes after something will be treated as string, causing to produce following action:
But there is a template handler that can help you with that.
ID: com.fireblink.fbl.flow.template
Aliases:
fbl.flow.templateflow.templatetemplatetpl
Example:
that will generally produce:
Action Handler: Virtual
Allows to create virtual action handler for another action (that can be represented as one of the flows).
ID: com.fireblink.fbl.flow.virtual
Aliases:
fbl.flow.virtualflow.virtualvirtual
Example:
Then you can reference your generated handler like any other:
Action Handler: Invoke
Allows to execute action passed as parameter. Can be used in pair with virtual to pass flow actions as parameters and create reach execution flow patterns.
ID: com.fireblink.fbl.flow.invoke
Aliases:
fbl.flow.invokeflow.invokeinvoke
Example:
Action Handler: Error
Throw error upon execution with given message.
ID: com.fireblink.fbl.flow.error
Aliases:
fbl.flow.errorflow.errorerror
Example:
Action Handler: Echo
Print message to console
ID: com.fireblink.fbl.flow.echo
Aliases:
fbl.flow.echoflow.echoecho
Example:
Action Handler: Void
Action handler that does nothing. Main usecase to bypass limitations of other action handlers that require action handler to be provided as an option, but you might not want to do that for some reason.
ID: com.fireblink.fbl.flow.void
Aliases:
fbl.flow.voidflow.voidvoid
Example:
Last updated
Was this helpful?