cancel
Showing results for 
Search instead for 
Did you mean: 

Call Activity - PropertyNotFoundException

diogosaad
Champ in-the-making
Champ in-the-making
Hello Folks,

I'm getting the following exception while trying to execute a process with a "Call Activity":
org.activiti.engine.ActivitiException: Unknown property used in expression
   at org.activiti.engine.impl.el.JuelExpression.getValue(JuelExpression.java:55)
   at org.activiti.engine.impl.el.UelExpressionCondition.evaluate(UelExpressionCondition.java:37)
   at org.activiti.engine.impl.bpmn.behavior.ExclusiveGatewayActivityBehavior.leave(ExclusiveGatewayActivityBehavior.java:63)
   …
Caused by: org.activiti.engine.impl.javax.el.PropertyNotFoundException: Cannot resolve identifier 'sector'
   at org.activiti.engine.impl.juel.AstIdentifier.eval(AstIdentifier.java:83)
   at org.activiti.engine.impl.juel.AstBinary$SimpleOperator.eval(AstBinary.java:27)
   at org.activiti.engine.impl.juel.AstBinary.eval(AstBinary.java:106)
   at org.activiti.engine.impl.juel.AstEval.eval(AstEval.java:50)
   at org.activiti.engine.impl.juel.AstNode.getValue(AstNode.java:26)
   at org.activiti.engine.impl.juel.TreeValueExpression.getValue(TreeValueExpression.java:114)
   at org.activiti.engine.impl.delegate.ExpressionGetInvocation.invoke(ExpressionGetInvocation.java:33)
   at org.activiti.engine.impl.delegate.DelegateInvocation.proceed(DelegateInvocation.java:37)
   at org.activiti.engine.impl.delegate.DefaultDelegateInterceptor.handleInvocation(DefaultDelegateInterceptor.java:25)
   at org.activiti.engine.impl.el.JuelExpression.getValue(JuelExpression.java:50)
I do have a "Parent" process which has a Call to a "Child" process and the "sector" variable is passed as a parameter to the child process.


<bpmn2:CallActivity id="any" name="" incoming="flow15" outgoing="flow14" calledElement="ChildProcess">
    <inParameters source="sectorInParent" target="sector"/>
    <outParameters source="result" target="resultFromChildProcess"/>
  </bpmn2:CallActivity>

How can I declare process variables ?

PS: In jbpm I just click on the process canvas and the eclipse properties view shows me "variables" property.
Is there something analogous in Activiti ?
4 REPLIES 4

trademak
Star Contributor
Star Contributor
Hi,

Process variables are not explicitly defined with Activiti.
So you just set process variables when starting a process instance or when executing a service task.

Best regards,

diogosaad
Champ in-the-making
Champ in-the-making
Hi,

Ok, but my interpretation about the error is correct? I mean, is it caused by non defined property (which is not defined by activiti modeler but MUST be defined in the bpmn xml file) ?


Thanks,
Diogo.

trademak
Star Contributor
Star Contributor
Hi,

It's cause by the fact that the sector process variable is not available in the process instance context.
You don't have to define it in the BPMN XML file.
Maybe it's better to start with the Activiti Designer to get started with what's possible with the Activiti Engine and read through the userguide.

Best regards,

diogosaad
Champ in-the-making
Champ in-the-making
I'm sorry but I still did not get it.

What must I do for it to be in the process instance context?
What I understood from the User Guide is that it's possible to map variables from the SuperProcess to the SubProcess, in other words, as long as the  superprocess has the  "sectorInParent" variable   the engine woud take care of creating the "sector" in the subprocess, as states by  <inParameters source="sectorInParent" target="sector"/>