AnsweredAssumed Answered

Timer start event not working

Question asked by vamsinipun on May 23, 2018
Latest reply on May 24, 2018 by bassam.al-sarori

Hi,

 

I am using activiti in my spring application and i would like to use timer start event for every minute. I designed the bpmn file and deployed. but it isn't working to trigger the business logic.

 

source code:

 

<?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:xsd="http://www.w3.org/2001/XMLSchema" 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="timeEventProcess" name="My process" isExecutable="true">
<startEvent id="timerstartevent1" name="Timer start">
<timerEventDefinition>
<timeDuration>P1M</timeDuration>
</timerEventDefinition>
</startEvent>
<serviceTask id="servicetask1" name="Service Task" activiti:class="org.nipun.it.activiti.listener.TimeEventListener"></serviceTask>
<sequenceFlow id="flow1" sourceRef="timerstartevent1" targetRef="servicetask1"></sequenceFlow>
<endEvent id="endevent1" name="End"></endEvent>
<sequenceFlow id="flow2" sourceRef="servicetask1" targetRef="mailtask1"></sequenceFlow>
<serviceTask id="mailtask1" name="Mail Task" activiti:type="mail">
<extensionElements>
<activiti:field name="to">
<activiti:string><![CDATA[vamsikrishna.g@nipun.net]]></activiti:string>
</activiti:field>
<activiti:field name="from">
<activiti:string><![CDATA[support@nipun.net]]></activiti:string>
</activiti:field>
<activiti:field name="subject">
<activiti:string><![CDATA[Activiti: Testing Timer]]></activiti:string>
</activiti:field>
<activiti:field name="html">
<activiti:string><![CDATA[Testing]]></activiti:string>
</activiti:field>
</extensionElements>
</serviceTask>
<sequenceFlow id="flow3" sourceRef="mailtask1" targetRef="endevent1"></sequenceFlow>
</process>
<bpmndi:BPMNDiagram id="BPMNDiagram_timeEventProcess">
<bpmndi:BPMNPlane bpmnElement="timeEventProcess" id="BPMNPlane_timeEventProcess">
<bpmndi:BPMNShape bpmnElement="timerstartevent1" id="BPMNShape_timerstartevent1">
<omgdc:Bounds height="35.0" width="35.0" x="80.0" y="40.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="servicetask1" id="BPMNShape_servicetask1">
<omgdc:Bounds height="55.0" width="105.0" x="160.0" y="30.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="endevent1" id="BPMNShape_endevent1">
<omgdc:Bounds height="35.0" width="35.0" x="450.0" y="40.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="mailtask1" id="BPMNShape_mailtask1">
<omgdc:Bounds height="55.0" width="105.0" x="310.0" y="30.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge bpmnElement="flow1" id="BPMNEdge_flow1">
<omgdi:waypoint x="115.0" y="57.0"></omgdi:waypoint>
<omgdi:waypoint x="160.0" y="57.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge bpmnElement="flow2" id="BPMNEdge_flow2">
<omgdi:waypoint x="265.0" y="57.0"></omgdi:waypoint>
<omgdi:waypoint x="310.0" y="57.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge bpmnElement="flow3" id="BPMNEdge_flow3">
<omgdi:waypoint x="415.0" y="57.0"></omgdi:waypoint>
<omgdi:waypoint x="450.0" y="57.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</definitions>

 

Please check and help me out of this.

 

Thanks

Outcomes