AnsweredAssumed Answered

Unknown property used in expression: #{bookOrder.validates()}

Question asked by ilyass_act on May 2, 2017
Latest reply on May 3, 2017 by ilyass_act

Hi everyone i tried CDI with Activiti but i keep getting this error :

Unknown property used in expression: #{bookOrder.validates()}

Caused by: org.activiti.engine.impl.javax.el.PropertyNotFoundException: Cannot resolve identifier 'bookOrder'

My BookOrder class : 

public class BookOrder {

private static final long serialVersionUID = 1L;

private String isbn;
private boolean approved;

public String getIsbn() {
return isbn;
public void setIsbn(String isbn) {
this.isbn = isbn;
public boolean isApproved() {
return approved;
public void setApproved(boolean approved) {
this.approved = approved;

public void validates() {
System.out.println("Testing the CDI ...");


and the BPMN file :

<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="" xmlns:xsi="" xmlns:xsd="" xmlns:activiti="" xmlns:bpmndi="" xmlns:omgdc="" xmlns:omgdi="" typeLanguage="" expressionLanguage="" targetNamespace="">
<process id="my-process" name="bookorder">
<startEvent id="startEvent" name="Start" activiti:formKey="taskForm_newOrder.jsf" />
<sequenceFlow id="toValidateTask" sourceRef="startEvent" targetRef="validateTask"/>
<serviceTask id="validateTask" activiti:expression="#{bookOrder.validates()}" />
<sequenceFlow id="toCompletedOrderTask" sourceRef="validateTask" targetRef="completeOrderTask"/>
<userTask id="completeOrderTask" name="Complete order" activiti:assignee="kermit" activiti:formKey="taskForm_completeOrder.jsf">
<documentation>Completing order for book with isbn </documentation>
<sequenceFlow id="toApproveTask" sourceRef="completeOrderTask" targetRef="approveTask"/>
<serviceTask id="approveTask" activiti:expression="#{bookOrder.validates()}" />
<sequenceFlow id="toEndEvent" sourceRef="approveTask" targetRef="endEvent"/>
<endEvent id="endEvent" name="End"/>


Any ideas what i'm doing Wrong here ??