Working with Intermediate Events

The Modeling perspective supports Intermediate events which follows BPMN 2.0 semantics. Intermediate Events are events that occur after a process has been started. An Intermediate Event affects the flow of the process by showing where messages and delays are expected, distributing the normal flow through exception handling. However, an Intermediate Event does not start or directly terminate a process.

Following sub-types are supported:

You can perform following operations on intermediate events:

Note
Models containing intermediate events may cause inconsistency warnings and errors when opened in the Eclipse-based modeler which may prevent direct deployment from the Eclipse-based modeler.

Adding Intermediate Events

In the toolbar, click Create Intermediate Event icon and drop it to swim lanes. By default, non-boundary Timer event gets created.


Figure: Create Intermediate Event

Adding Boundary Event

To add the boundary event, click the Create Intermediate Event icon and drop it on activity or on the boundary of an activity.


Figure: Add Boundary Event

By default, Timer boundary event gets added. You can also define Error event as boundary event.


Figure: Boundary Event

Note that Boundary events must have an exception flow.

Adding Non-boundary Events

To add the non-boundary event, click the Create Intermediate Event icon and drop it on the diagram canvas between two activities or activity and gateway.


Figure: Non-boundary Event

Note that only Timer event can be added as a non-boundary event. Non-boundary event is always between two activities, or gateway and activity. Non-Boundary Intermediate Events should have one inbound and one outbound sequence flow, otherwise a warning is issued during model deployment.

For non-boundary timer event, the activity goes into Hibernate state till the time period is defined. Once the time period criteria meets, the next activity gets activated by completing a timer for the underline activity.

Dos and Don'ts for Boundary Event Modeling

The following topology rules should be followed when modeling intermediate events in the Modeling perspective:

Using Intermediate Event Flyout Menu

The intermediate event flyout menu is displayed when you hover the mouse in the proximity of the data.


Figure: Intermediate Event - Flyout Menu

Menu Icon Menu Option Description
Connect Adds a Sequence Flow or Exception Flow with the event as the first endpoint
New Activity Adds a new manual activity with sequence flow or exception flow connecting the event to the new activity.
New Gateway Adds a new Gateway(XOR) with sequence flow or exception flow connecting the event to the new gateway.
Delete Deletes the event.

Viewing and Editing Properties

General Properties

Following properties are supported:

Comments

To add comments for events, perform the following steps:

  1. Click the Comments icon displayed at the top right corner of the swim lane


    Figure: Start Event - Comment Icon

  2. Add comment in the text box and click Submit. The newest comment gets displayed at the top of the table.


    Figure: End Event - Comment

  3. To delete the comment, select the comment and click the Delete icon. The user, who has submitted the comment, only that user can delete the comment. If the other user selects the comment or no comment is selected, the Delete icon remains in disabled state.

Timer Event - Implementation

This option is available only when you switch to Integrator profile.

Note that you need to start Event Daemon when working with Timer Event. For more information about event daemon, please refer to the chapter Managing Daemons of the Infinity Portal documentation.


Figure: Timer Event - Implementation

You can specify following implementation properties:

Note that the Automatic Binding option is not supported in the Modeling perspective. However, it is implicitly set to True.

The Consume On Match option is also not supported in the Modeling perspective. However, it is implicitly set to False.

Error Boundary Event - Implementation

This option is available only when you switch to Integrator profile. Note that you need to start Event Daemon when working with Error Event.

The Error Boundary Events may only be Interrupting, meaning when the event is triggered the Activity that it is bound to is aborted and the exception path follows. The following properties are displayed:


Figure: Error Event - Implementation

Note that the Automatic Binding option is not supported in the Modeling perspective. However, it is implicitly set to True.

If there are multiple error boundary events, the exception hierarchies should be disjunct. For example, for Activity 1 two error boundary events are added in order say java.lang.IllegalAccessException and General(java.lang.Exception).


Figure: Multiple Error Boundary Events

Then, in this case warning is displayed at the time of model deployment. Note that you can either specify super class or sub class of the exception. If you specify both then in that case an error is displayed at the time of deployment.


Figure: Multiple Error Event - Deployment Validation

Binding and Unbinding Boundary Events to and from Activities

Binding Boundary Events

To bind boundary events to an activity, they can be dropped onto another activity or the drawing canvas. The existing exception flow, e.g. a connection, is maintained in that case.

When binding an unbound event that has incoming and outgoing connections, the incoming is deleted, whereas the outgoing is maintained. An exception is thrown when the event is bound to the activity that is attached to the event's outgoing connection. In this case, both the incoming and outgoing connections are deleted.

Unbinding Boundary Events

Boundary Events can be unbound from activities via drag-and-drop.

Examples

Note
To execute following examples, please start Event Daemon.

Interrupting Timer Boundary Event

In the following example, Timer event is specified for the activity named ProcessActivityInTime. If the user does not complete this activity before the specified time interval, the timer is reached and the exception flow is followed.

  1. Create a model as shown in the following screenshot


    Figure: Timer Boundary Event - Example

    Note that the timer event is Interrupting.


    Figure: Interrupting Timer Event

  2. Now deploy the model and switch to the Workflow Execution perspective.
  3. Activate the process instance
  4. Click the Suspend option
  5. Switch to the Administration perspective and open the Activity Overview panel. Note that the status of the ProcessActivityInTime activity is Aborted and the exception flow activity named TimerExceptionFlow is in Suspended state.


    Figure: Activity Overview

Non-interrupting Timer Boundary Event

Scenario 1

In the following example, the user waits for the specified time interval so that the normal flow is followed.

  1. Create a model as shown in the following screenshot:


    Figure: Timer Boundary Event - Example

    Note that the timer event is non-interrupting.


    Figure: Non-interrupting Timer Event

  2. Now deploy the model and switch to the Workflow Execution perspective.
  3. Activate the activity named SourceActivity and wait for 5 seconds
  4. Check that it is still active
  5. Complete the activity SourceActivity
  6. Check that the activity named NormalFlow is followed
  7. Check the activity status in the Activity Overview panel of the Administration perspective. Note that the activity named ExceptionFlow is in Suspended state.


    Figure: Activity Overview

Scenario 2

In the following scenario, the user completes the activity to which the timer event is bound before the timer is over.

  1. Activate the SourceActivity and complete it before the specified timer is over
  2. Wait for the time out
  3. Verify that boundary event transition is not followed. In the Activity Overview panel it does not display the status of the activity named ExceptionFlow.


    Figure: Activity Overview

Timer Non-boundary Event

In the following example, the user completes the SourceActivity and once the timer is reached, the next activity executes.

  1. Create a model as shown in the following screenshot


    Figure: Timer Non-boundary Event - Example

  2. Specify the timer implementation properties


    Figure: Timer Non-boundary Event - Implementation

  3. Now deploy the model and switch to the Workflow Execution perspective.
  4. Activate the activity named SourceActivity and complete it

    Note that the next activity named TargetActivity is initiated only when the timer is reached.

  5. Open the worklist of the user to activate and complete the next activity.


    Figure: Worklist - Non-boundary Timer Event Activity

Error Boundary Event

In the following example, the user completes the activity named FirstActivity. Then, the application activity MessageTransformation is executed. If the general exception is thrown then the exception flow is followed.

  1. Create a model as shown in the following screenshot


    Figure: Error Boundary Event - Example

  2. Specify the error event implementation properties


    Figure: Error Boundary Event - Implementation

  3. Now deploy the model and switch to the Workflow Execution perspective.
  4. Activate the activity named FirstActivity and complete it. Note that the ErrorFlow activity is followed.
  5. Switch to the Administration perspective and open the Activity Overview panel. Note that the MessageTransformation activity is in Aborted state.


    Figure: Activity Overview