Having a stage or task with sentry (entry) could not be moved from available to enabled state. There is no onPart criteria as well. Stage has manual activation set to false. When I set the variable ${external_request} to true nothing happened. If I set the same variable on starting of the CMMN process the stage goes to enabled state directly as expected. What am I missing?
Sorry, that it is
<cmmn:sentry id="_9e777a84-d526-4475-9173-07f203ccbd23"> <cmmn:ifPart id="_bfcb947b-256e-41ab-b908-a24563dd30f4"> <cmmn:condition id="_0d653305-994e-4180-a3e2-490677946811"><![CDATA[${caseExecution.getVariable("request_internal")||caseExecution.getVariable("request_external")}]]></cmmn:condition> </cmmn:ifPart> </cmmn:sentry>
and this is the process, the marked sentry is the described with the snippet.
Hi @bbanchev,
That’s a limitation of the CMMN engine.
The docs on Sentry ifParts says:
The engine evaluates IfParts at every lifecycle transition of a plan item contained in the sentry’s stage. That means, if an IfPart is not satisfied immediately when all OnParts have occurred, the sentry may still occur at any later lifecycle transition.
Since setting a variable does not trigger a lifecycle transition, the sentry is not re-evaluated at that point. See this ticket that addresses this topic:
https://app.camunda.com/jira/browse/CAM-5946
Cheers,
Thorben
I see what I am missing now. Thank you