Allow passive resource acquisition according to a StoEx
AcquireActions and ReleaseActions inherit from AbstractInternalControlFlowAction the attribute resourceDemand_Action. This attribute can be used to specify the number of resource instances to be acquired or released. EventSim, however, currently assumes the number to be one. If a StoEx is given, it is not evaluated and an exception is thrown.
Rather, EventSim should evaluate a StoEx if present. Without a StoEx specified, EventSim should assume "1" for the number of acquired resource instances.
Great - , Thanks a lot! From a first simulation using our model it looks good! We do use variables to specify the parametric resource demands for acquire/release actions and it even works in these cases.
, could you please check if this solves your requirements.
It turned out that SimuCom ignores such a StoEx as well, assuming "1". This is mainly due to conceptual reasons:
1) the StoEx refers to a resource type like CPU, HDD, ... but actually not to the number of passive resource instances. Still using the StoEx for describing the number of acquired (released) resource instances is somewhat a "PCM-Hack"
2) One must be careful to avoid stochastic expressions within a ParametricResourceDemand and limit oneself to use constants (and variables?). Otherwise, the number of acquired instances is likely to mismatch the number of released instances (due to different draws from a probability distribution), leading to a "leak" of passive resource instances.
I will still implement this as an experimental feature.