Extra Variables created in MultiInstance Activities

Description

The SequentialMultiInstanceBehavior class creates the following variables (nrOfInstances, nrOfCompletedInstances, and nrOfActiveInstances) on the execution of the User Task. Based upon Table 10.30 (Multi-instance Activity instance attributes) on p194 of the BPM 2 spec, I believe these variables (with IDs 21,23,25 respectively in the attached file) should not be created as they should only be provided on the “outer instance of the Multi-Instance Activity” which is execution 7.

In addition, based on the same table in the BPMN 2 spec, the loopCounter variable should only be provided on the "(inner) instance of the Activity" which is execution 12. Therefore I would not expect the loopCounter variable with id=19 to be created.

Opening this issue to request that the core Activiti developers take a further look in to the behavior.

Environment

None

Status

Assignee

Elias Ricken de Medeiros

Reporter

Robert Hafner

Labels

None

Components

Fix versions

Affects versions

Priority

High
Configure