Wait-for-AAEvent Activity in a Workflow
- Last UpdatedJun 10, 2024
- 2 minute read
The Wait-for-AAEvent Activity is used to wait for an ArchestrA event within a workflow. An event should be specified for the specific object in System Platform IDE.
In the following example, an event called Spill will occur when the object’s Cycle attribute value changes to six. We will configure a process that waits for the event Spill to occur. After the event occurs, the context parameters of the event are captured.
-
Create an Event Expression Me.Cycle==6.
-
Pass relevant parameters.
-
Click on the Manage Workflow menu.
The Workflow list appears.
-
You can either create a new workflow process which will wait for a Spill event or select a workflow which should wait for the Spill event.
-
Create a new workflow.
The Process Designer window appears.
-
Select ArchestrA from the activities drop-down menu.
-
Drag Wait-for-AAEvent activity to the designer pane.
The Wait-for-AAEvent Set Event Filters screen appears.
-
Enter the required details.
Click Save & Close to save the property.
Note: The Workflows which are associated at the template level, wait for the respective template instances.
Defined In Object Name in the Wait-for-AAEvent Set Event Filters property is used to capture the object or template name in which the specific instance is defined. The instance name is passed while starting the workflow and it can be accessed through variables.
For example, consider a workflow associated with an alarm template. Workflow is triggered whenever the alarm status is ON. Alarm can have multiple instances like Temperature alarm and Pressure alarm.
-
If the status of both Temperature and Pressure alarm is ON, two instances of the same workflow will be triggered.
-
The workflows internally wait for the respective alarm's status to be OFF. When the Temperature alarm status is OFF, the workflow which was triggered by the Temperature alarm will proceed and it will not affect the other instance of the workflow which was triggered by the Pressure alarm.
Object Name in the Wait-for-AAEvent Set Event Filters property is used to capture the name of the instance, which triggered this event.
-
-
Click on the icon in the Create Output XMLVariable property.
The Create Output XmlVariable screen appears.
-
Enter a unique XML variable name.
-
Click Save & Close.
An XML Variable with the structure of the ArchestrA context parameters is created and the same is populated in the ArchestrA Data XML variable drop-down menu.
-
Save the property to save the ArchestrA Context XMLVariables.
-
Access the XML variables property of the Start activity for verifying the newly created variable.
Note: Both the properties explained above use ArchestrA context values. When the Enterprise Console is accessed, ArchestrA context related variables needs to be set manually.