Model
A WorkflowModel
represents a definition (model) of a workflow. It is made of WorkflowNodes
and WorkflowTransitions
. The transitions connect the nodes and define the flow. The Model always has a start node and an end node.
Runtime Model
Workflow models are versioned. When you run a workflow instance, it uses and keeps the runtime model of the workflow, as available at the time the workflow was started.
A runtime model is generated when Sync is triggered in the workflow model editor.
Edits to the workflow model that occur, or runtime models that are generated, or both, after the specific instance was started are not applied to that instance.
Step
Each step accomplishes a discrete task. There are different types of workflow steps:
- Participant (User/Group): These steps generate a work item and assign it to a user or group. A user must complete the work item to advance the workflow.
- Process (Script, Java™ method call): These steps are executed automatically by the system. An ECMA script or Java™ class implements the step. Services can be developed to listen to special workflow events and perform tasks according to the business logic.
- Container (Sub Workflow): This type of step starts another workflow model.
- OR Split/Join: Use logic to decide which step to execute next in the workflow.
- AND Split/Join: Allows multiple steps to be executed simultaneously.
All the steps share the following common properties: Autoadvance
and Timeout
alerts (scriptable).
Transition
A WorkflowTransition
represents a transition between two WorkflowNodes
of a WorkflowModel
.
- It defines the link between two consecutive steps.
- It is possible to apply rules.
WorkItem
A WorkItem
is the unit that is passed through an Workflow
instance of a WorkflowModel
. It contains the WorkflowData
that the instance acts on and a reference to the WorkflowNode
that describes the underlying workflow step.
- It is used to identify the task and is put into the respective inbox.
- A workflow instance can have one or many
WorkItems
at the same time (depending on the workflow model). - The
WorkItem
references the workflow instance. - In the repository, the
WorkItem
is stored below the workflow instance.
Payload
References the resource that has to be advanced through a workflow.
The payload implementation references a resource in the repository (by path, UUID, or URL) or by a serialized Java™ object. Referencing a resource in the repository is flexible and, with sling productive. For example, the referenced node could be rendered as a form.
Lifecycle
Is created when starting a new workflow (by choosing the respective workflow model and defining the payload) and ends when the end node is processed.
The following actions are possible on a workflow instance:
- Terminate
- Suspend
- Resume
- Restart
Completed and terminated instances are archived.
Inbox
Each user account has its own workflow inbox in which the assigned WorkItems
are accessible.
The WorkItems
are assigned to either the user account directly or to the group to which they belong.
Workflow Types
There are various types of workflow as indicated in the Workflow Models console:
-
Default
These types are the out-of-the-box workflows included in a standard AEM instance.
-
Custom workflows (no indicator in the console)
These workflows have been created as new, or from out-of-the-box workflows that have been overlaid with customizations.
-
Legacy
Workflows created in a prior version of AEM. These workflows can be retained during an upgrade, or exported as a workflow package from the prior version, then imported into the new version.
Transient Workflows
Standard workflows save runtime (history) information during their running. You can also define a workflow model as Transient to avoid such history being persisted. This workflow is used for performance tuning because it saves time and resources that are used for persisting the information.
Transient workflows can be used for any workflows that:
- are run often.
- do not need the workflow history.
Transient workflows were introduced for loading many assets, where the asset information is important, but not the workflow runtime history.
- The payload type (for example, video) requires external steps for processing; in such cases the runtime history is needed for status confirmation.
- The workflow enters an AND Split. In such cases, the runtime history is needed for status confirmation.
- When the transient workflow enters a participant step, it changes mode, at runtime, to non-transient. As the task is being passed to a person, the history must be persisted.
goto
point. It defeats the purpose of making the workflow transient, and generates an error in the log file.Multi Resource Support
Activating Multi Resource Support for your workflow model means that a single workflow instance is started even when you select multiple resources. Each is attached as a package.
If Multi Resource Support is not activated for your workflow model and multiple resources are selected, then an individual workflow instance is started for each resource.
Workflow Stages
Workflow Stages help visualize the progress of a workflow when handling tasks. They can be used to provide an overview of how far the workflow is through processing. When the workflow runs, the user can view the progress described by Stage (as opposed to individual step).
As the individual step names can be specific and technical, the stage names can be defined to provide a conceptual view of the workflow progress.
For example, for a workflow with six steps and four stages:
-
- Multiple stage names can be created.
- Then an individual stage name is assigned to each step (a stage name can be assigned to one or more steps).
Step Name Stage (assigned to the step) Step 1 Create Step 2 Create Step 3 Review Step 4 Approve Step 5 Complete Step 6 Complete -
When the workflow is run, the user can view the progress according to the Stage names (instead of the step names). The workflow progress is displayed in the WORKFLOW INFO tab of the task details window of the workflow item listed in the Inbox.
Workflows and Forms
Typically, workflows are used to process form submissions in AEM. It can be with the core components form components available in a standard AEM instance, or with the AEM Forms solution.
When creating a form, the form submission can be easily associated with a workflow model. For example, to store the content in a particular location of the repository or to notify a user about the form submission and its content.
Workflows and Translation
Workflows are also a part of the Translation process.
Experience Manager
Driving Marketing Agility and Scale: Transforming your Content Supply Chain with AI
Marketers everywhere are feeling the pressure to deliver impactful campaigns faster and at greater scale. This Strategy Keynote explores...
Tue, Mar 18, 2:30 PM PDT (9:30 PM UTC)
Rapid Feature Releases with AEM Cloud: Telegraph Media Group’s RDE Strategy
Hear how Telegraph Media Group, the award-winning publisher of The Daily Telegraph, The Sunday Telegraph, The Telegraph Magazine,...
Wed, Mar 19, 3:30 PM PDT (10:30 PM UTC)
Connect with Experience League at Summit!
Get front-row access to top sessions, hands-on activities, and networking—wherever you are!
Learn more