Files
govoplan-workflow-engine/tests/fixtures/bpmn/events-transaction-compensation.bpmn

43 lines
1.6 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<bpmn:definitions
xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL"
id="Definitions_Events"
targetNamespace="urn:govoplan:workflow:fixtures">
<bpmn:message id="Message_Continue" name="Continue" />
<bpmn:error id="Error_Processing" name="Processing failed" errorCode="PROCESSING" />
<bpmn:process id="Process_Transaction" isExecutable="true">
<bpmn:startEvent id="Start_Timer">
<bpmn:timerEventDefinition id="Timer_Start_Definition">
<bpmn:timeCycle>R3/PT1H</bpmn:timeCycle>
</bpmn:timerEventDefinition>
</bpmn:startEvent>
<bpmn:transaction id="Transaction_1">
<bpmn:serviceTask id="Charge_Account" name="Charge account" />
<bpmn:boundaryEvent
id="Charge_Error"
attachedToRef="Charge_Account">
<bpmn:errorEventDefinition
id="Charge_Error_Definition"
errorRef="Error_Processing" />
</bpmn:boundaryEvent>
<bpmn:task
id="Undo_Charge"
name="Undo charge"
isForCompensation="true" />
<bpmn:association
id="Compensation_Association"
sourceRef="Charge_Error"
targetRef="Undo_Charge"
associationDirection="One" />
</bpmn:transaction>
<bpmn:intermediateCatchEvent id="Wait_For_Continue">
<bpmn:messageEventDefinition
id="Wait_Message_Definition"
messageRef="Message_Continue" />
</bpmn:intermediateCatchEvent>
<bpmn:endEvent id="End_Transaction">
<bpmn:terminateEventDefinition id="Terminate_Definition" />
</bpmn:endEvent>
</bpmn:process>
</bpmn:definitions>