<?xml version="1.0" encoding="UTF-8"?> 
<definitions id="Definition"
             targetNamespace="http://www.example.org/MinimalExample"
             typeLanguage="http://www.java.com/javaTypes"
             expressionLanguage="http://www.mvel.org/2.0"
             xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
             xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd"
             xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
             xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
             xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
             xmlns:tns="http://www.jboss.org/drools">

  <itemDefinition id="_xItem" />

  <process processType="Private" isExecutable="true" id="CompensateIntermediateThrowEvent" name="Compensate Intermediate Throw Event Process" >

    <!-- process variables -->
    <property id="x" itemSubjectRef="_xItem"/>

    <!-- nodes -->
    <startEvent id="_1" name="StartProcess" />
    <scriptTask id="_2" name="Task" >
      <script>System.out.println("Executing task");</script>
    </scriptTask>
    <intermediateThrowEvent id="_3" name="CompensateEvent" >
      <compensateEventDefinition activityRef="_2"/>
    </intermediateThrowEvent>
    <endEvent id="_4" name="EndEvent" />
    <boundaryEvent id="_5" name="CompensateEvent" attachedToRef="_2" >
      <compensateEventDefinition/>
    </boundaryEvent>
    <scriptTask id="_6" name="Compensate" >
      <script>System.out.println("Compensating task");</script>
    </scriptTask>
    <endEvent id="_7" name="EndEvent" />

    <!-- connections -->
    <sequenceFlow id="_1-_2" sourceRef="_1" targetRef="_2" />
    <sequenceFlow id="_2-_3" sourceRef="_2" targetRef="_3" />
    <sequenceFlow id="_3-_4" sourceRef="_3" targetRef="_4" />
    <sequenceFlow id="_5-_6" sourceRef="_5" targetRef="_6" />
    <sequenceFlow id="_6-_7" sourceRef="_6" targetRef="_7" />

  </process>

  <bpmndi:BPMNDiagram>
    <bpmndi:BPMNPlane bpmnElement="CompensateIntermediateThrowEvent" >
      <bpmndi:BPMNShape bpmnElement="_1" >
        <dc:Bounds x="16" y="16" width="48" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="_2" >
        <dc:Bounds x="96" y="16" width="80" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="_3" >
        <dc:Bounds x="208" y="16" width="158" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="_4" >
        <dc:Bounds x="405" y="16" width="48" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="_5" >
        <dc:Bounds x="138" y="46" width="48" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="_6" >
        <dc:Bounds x="102" y="138" width="117" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="_7" >
        <dc:Bounds x="273" y="137" width="48" height="48" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge bpmnElement="_1-_2" >
        <di:waypoint x="40" y="40" />
        <di:waypoint x="136" y="40" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="_2-_3" >
        <di:waypoint x="136" y="40" />
        <di:waypoint x="287" y="40" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="_3-_4" >
        <di:waypoint x="287" y="40" />
        <di:waypoint x="429" y="40" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="_5-_6" >
        <di:waypoint x="162" y="70" />
        <di:waypoint x="160" y="162" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="_6-_7" >
        <di:waypoint x="160" y="162" />
        <di:waypoint x="297" y="161" />
      </bpmndi:BPMNEdge>
    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>

</definitions>