BusinessProcessSimulation/BPSim

Resource Selection extension

Opened this issue · 1 comments

In many business processes the particular resource instance that is selected for a task must stay with that piece of work (token) through later steps. This named resourced could be stored as an attribute of the token and referred to in a subsequent resource selection expression.

This implementation could also be used to stop a particular resource being used at a later step to work on a token. This functionality is sometimes required to make sure a quality check is performed by a different resource instance to the one that did the work, even though they maybe both doing the same role.

One possible solution would be to introduce an evaluation moment for the property (evaluateAt) and introduce a getCurrentPerformer() method to xpath.

<ElementParameters elementRef="Task1">
    <ResourceParameters>
        <Selection >
            <ExpressionParameter value="orResource(getProperty('storedFromA') , getResource('finance', 2) | getResource('sales', 50))" />
        </Selection>
    </ResourceParameters>
    <PropertyParameter>
        <Property name="storedFromA" evaluateAt="end">
            <ExpressionParameter  value="getCurrentPerformer()"  />
        <Property>
    </PropertyParameter>
</ElementParameters>