AnsweredAssumed Answered

org.activiti.spring.test.components example not working.

Question asked by pavan.bukka.ait on Jun 18, 2012
Latest reply on Jun 19, 2012 by pavan.bukka.ait
Hi,
   i am trying org.activiti.spring.test.components example given in spring distrubution in my application and i have written the following code to start the process
                           Deployment d=repositoryService.createDeployment()
            .addClasspathResource("autodeploy.b.bpmn20.xml")            
            .deploy();
                      String processInstanceId =  processInitiatingPojo.startProcessA(22);

process definition is getting deployed properly deploymentId i can see the Deployment object d . when starting the process startProcessA function returning null means , i think process is not getting started .
and the content of autodeploy.b.bpmn20.xml is

<?xml version="1.0" encoding="UTF-8"?>

<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:activiti="http://activiti.org/bpmn" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:omgdc="http://www.omg.org/spec/DD/20100524/DC" xmlns:omgdi="http://www.omg.org/spec/DD/20100524/DI" typeLanguage="http://www.w3.org/2001/XMLSchema" expressionLanguage="http://www.w3.org/1999/XPath" targetNamespace="http://www.activiti.org/test">
 
  <process id="b">
 
    <startEvent id="start" />
    <sequenceFlow id="flow1" sourceRef="start" targetRef="end" />
   
    <endEvent id="end" />
   
  </process>
 
  <bpmndi:BPMNDiagram id="BPMNDiagram_MyProcess">
    <bpmndi:BPMNPlane bpmnElement="b" id="BPMNPlane_MyProcess">
      <bpmndi:BPMNShape bpmnElement="start" id="BPMNShape_start">
        <omgdc:Bounds height="35" width="35" x="130" y="180"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="end" id="BPMNShape_end">
        <omgdc:Bounds height="35" width="35" x="250" y="180"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge bpmnElement="flow1" id="BPMNEdge_flow1">
        <omgdi:waypoint x="165" y="197"></omgdi:waypoint>
        <omgdi:waypoint x="250" y="197"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>

</definitions>
and the definition of startProcessA function is .
   @StartProcess(processKey = "b")
   public void startProcess(@ProcessVariable("customerId") long customerId) {
      log.info("starting 'b' with customerId # " + customerId);
      this.methodState += 1;
      log.info("up'd the method state");
   }


but the same example working well in the spring distribution.
Please help me to fix this problem.
Thanks in advance…


Kind regards,
Bukka pavan kumar.

Outcomes