Official Plugins (Kuzzle v2.x)
Workflows v0.x

This plugin is part of the Kuzzle Enterprise Plan. If you are interested, please contact us.

Workflow Plugin Overview #

This plugin allows you to define Workflows for data processing.

These Workflows are composed of conditions to be fulfilled, and actions to be performed.

Workflow definitions are dynamic, and their behavior can be modified at runtime, without restarting the application.

Workflow #

Workflows are defined in documents stored in a database. Each document contains the configuration of a Workflow.

All Workflows are stored in the config collection in a Kuzzle index. They are config document with a type property set to workflow.

Workflows are composed of two sub parts:

  • trigger: set of constraints to be met in order to execute the actions
  • actions: set of actions to execute in a defined order


Some examples of what you can achieve with Workflows:

  • Enrich documents with geofencing, states-machine, external API, ...
  • Execute custom actions like sending email, http callback, ...

Predicate & Task #

Predicates and Tasks are part of the Workflow execution cycle.

A Predicate is a dynamic condition for the execution of a Workflow while a Task is an action to be performed once all conditions of the Workflow have been met.

Concretely, they are classes containing code to be executed in order to allow a high level of customization of Workflows.

These classes are registered by the plugin and then they can be used in Workflows.

Rule #

Rules are also stored as documents in the database in a config collection. They are config documents with a type property set to rule.

A Rule is one of the actions that can be performed by Workflow once its condition have been fulfilled.

A Rule is composed of a condition and actions.

Rules allow to define more complex actions than what is achievable by Tasks, such as geofencing-based document enrichment or state-machines.


Engine Controller & Multi Tenancy #

A Workflow engine works on a particular index by subscribing to changes in the workflows and rules collections.

It is possible to create, update or delete Workflow engines using the EngineController.

This allows to have Workflow engines isolated by index and thus to work in a multi-tenant environment.