Скачиваний:
25
Добавлен:
28.01.2021
Размер:
7.15 Mб
Скачать

If the isImmediate attribute of a Sequence Flow has a value of false or no value, then Participants MAY send Messages to each other between the elements connected by the Sequence Flow without additional

Choreography Activities in the Choreography. If the isImmediate attribute of a Sequence Flow has a value of true, then Participants MAY NOT send Messages to each other between the elements connected by the

Sequence Flow without additional Choreography Activities in the Choreography. The value of isImmediate attribute of a Sequence Flow has no effect if the isClosed attribute of the containing

Choreography has a value of true.

Restrictions on unmodeled messaging specified with isClosed and isImmediate applies only under the Choreography containing the restriction. PartnerEntities and PartnerRoles of the Participants MAY send

Messages to each other under other Choreographies, Collaborations, and Conversations.

11.4.2 Artifacts

Both Text Annotations and Groups can be used within Choreographies and all BPMN diagrams. There are no restrictions on their use.

11.5 Choreography Activities

A Choreography Activity represents a point in a Choreography flow where an interaction occurs between two or more Participants.

The Choreography Activity class is an abstract element, sub-classing from FlowElement (as shown in Figure 11.6). When Choreography Activities are defined they are contained within a Choreography or a Sub-Choreography, which are FlowElementContainers (other FlowElementContainers are not allowed to contain

Choreography Activities).

Business Process Model and Notation (BPMN), v2.0.2

321

Figure 11.6 – The metamodel segment for a Choreography Activity

The Choreography Activity element inherits the attributes and model associations of FlowElement (see Table 8.44) through its relationship to FlowNode. Table 11.1 presents the additional model associations of the Choreography Activity element.

Table 11.1 – Choreography Activity Model Associations

Attribute Name

Description/Usage

 

 

participantRefs: Participant [2..*]

A Choreography Activity has two or more Participants (see page 113 for

 

more information on Participants).

 

 

initiatingParticipantRef:

One of the Participants will be the one that initiates the Choreography

Participant

Activity.

 

 

 

loopType:

A Choreography Activity MAY be performed once or MAY be repeated.

ChoreographyLoopType = None

The loopType attribute will determine the appropriate marker for the

 

 

Choreography Activity (see below).

 

 

correlationKeys:

This association specifies correlationKeys used by the Message Flow

CorrelationKey [0..*]

in the Choreography Activity, including Sub-Choreographies and called

 

 

Choreographies.

 

 

322

Business Process Model and Notation (BPMN), v2.0.2

11.5.1 Choreography Task

A Choreography Task is an atomic Activity in a Choreography Process. It represents an Interaction, which is one or two Message exchanges between two Participants. Using a Collaboration diagram to view these elements (see page 107 for more information on Collaboration), we would see the two Pools representing the two Participants of the Interaction (see Figure 11.7). The communication between the Participants is shown as a Message Flow.

Participant A

Participant B

Figure 11.7 – A Collaboration view of Choreography Task elements

In a Choreography diagram, this Interaction is collapsed into a single object, a Choreography Task. The name of the Choreography Task and each of the Participants are all displayed in the different bands that make up the shape’s graphical notation. There are two or more Participant Bands and one Task Name Band (see Figure 11.8).

The Participant Band of the Participant that does not initiate the interaction MUST be shaded with a light fill.

Initiating

 

 

Participant

 

 

Band

Participant A

 

 

Choreography

Task Name

 

Task Name

 

Band

 

 

Participant

Participant B

 

Band

 

 

Figure 11.8 – A Choreography Task

 

Business Process Model and Notation (BPMN), v2.0.2

323

Participant A

Send

Message

 

Initiating

 

Message

B

 

Participant

Receive

Message

 

Figure 11.9 – A Collaboration view of a Choreography Task

The interaction defined by a Choreography Task can be shown in an expanded format through a Collaboration diagram (see Figure 11.9 and see page 107 for more information on Collaborations). In the Collaboration view, the Participants of the Choreography Task Participant Band’s will be represented by Pools. The interaction between them will be a Message Flow.

Initiating

Message

Participant A

Choreography

Task Name

Participant B

Return

Message

Figure 11.10 – A two-way Choreography Task

324

Business Process Model and Notation (BPMN), v2.0.2

Participant A

Send

and Receive

Messages

Initiating

Return

Message

Message

Participant B

Receive

Send

Message

Message

Additional Internal Activities may occur between

Figure 11.11 – A Collaboration view of a two-way Choreography Task

In a Choreography Diagram, the Choreography Task object shares the same shape as a Task or any other BPMN Activity, which is a rectangle that has rounded corners.

A Choreography Task is a rounded corner rectangle that MUST be drawn with a single line.

The use of text, color, size, and lines for a Choreography Task MUST follow the rules defined in “Use of Text, Color, Size, and Lines in a Diagram” on page 39.

The three bands in the Choreography Task shape provide the distinction between this type of Task and an Orchestration Task (in a traditional BPMN diagram).

The Message sent by either one or both of the Participants of the Choreography Task can be displayed (see Figure 11.10, above). The Message icon is shown tethered to the Participant that is the sender of the Message.

If the Message is the initiating Message of the Choreography Task, then the Message icon MUST be unfilled.

If the Message is a return Message for the Choreography Task, then the Message icon MUST have a light fill.

Note that Messages can be tethered to a Call Choreography that references a GlobalChoreographyTask, but cannot be used for Sub-Choreographies or Call Choreography that references another Choreography.

As with a standard Orchestration Task, the Choreography Task MAY have internal markers to show how the Choreography Task MAY be repeated. There are two types of internal markers (see Figure 11.12):

A Choreography Task MAY have only one of the three markers at one time.

The marker for a Choreography Task that is a standard loop MUST be a small line with an arrowhead that curls back upon itself. The loopType of the Choreography Task MUST be Standard.

Business Process Model and Notation (BPMN), v2.0.2

325

The marker for a Choreography Task The loopType of the Choreography

that is parallel multi-instance MUST be a set of three vertical lines.

Task MUST be MultiInstanceParallel.

The marker for a Choreography Task that is sequential multi-instance MUST be a set of three horizontal lines. The loopType of the Choreography Task MUST be MultiInstanceSequential.

The marker that is present MUST be centered at the bottom of the Task Name Band of the shape.

P articipant A

 

P articipan t A

Participant A

C horeography

 

C horeo gra phy

 

C horeography

Task N am e

 

Ta sk N a me

 

Task N am e

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

P articipant B

 

P articipan t B

 

Participant B

Figure 11.12 – Choreography Task Markers

Participant A

Se nd Me ssag e

Messa ge

B

 

Participant

R ece ive

Me ssag e

 

Figure 11.13 – The Collaboration view of a looping Choreography Task

326

Business Process Model and Notation (BPMN), v2.0.2

Participant A

Send

Message

Message

B

 

Participant

R eceive

Message

 

Figure 11.14 – The Collaboration view of a Parallel Multi-Instance Choreography Task

There are situations when a Participant for a Choreography Task is actually a multi-instance Participant. A multiinstance Participant represents a situation where there are more than one possible related Participants (PartnerRoles/ PartnerEntities) that might be involved in the Choreography. For example, in a Choreography that involves the shipping of a product, there can be more than one type of shipper used, depending on the destination. When a Participant in a Choreography contains multiple instances, then a multi-instance marker will be added to the Participant Band for that Participant (see Figure 11.15).

The marker for a Choreography Task that is multi-instance MUST be a set of three vertical lines. The marker that is present MUST be centered at the bottom of the Participant Band of the shape.

The width of the Participant Band will be expanded to contain both the name of the Participant and the multi-instance marker.

Participant A

Choreography

Task Name

Participant B

Figure 11.15 – A Choreography Task with a multiple Participant

Business Process Model and Notation (BPMN), v2.0.2

327