<?xml version='1.0' encoding='utf-8'?>
<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" 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" id="WarehouseDefinition" targetNamespace="urn:kaskad:warehouse">
  <bpmn:process id="Warehouse" name="Warehouse reconciliation (TO-BE)" isExecutable="false">
    <bpmn:startEvent id="Start" name="Start">
      <bpmn:outgoing>Flow_0</bpmn:outgoing>
    </bpmn:startEvent>
    <bpmn:task id="Extract" name="Extract movements">
      <bpmn:incoming>Flow_0</bpmn:incoming>
      <bpmn:outgoing>Flow_1</bpmn:outgoing>
    </bpmn:task>
    <bpmn:task id="Calculate" name="Calculate balance">
      <bpmn:incoming>Flow_1</bpmn:incoming>
      <bpmn:outgoing>Flow_2</bpmn:outgoing>
    </bpmn:task>
    <bpmn:exclusiveGateway id="Decision" name="Discrepancy found?">
      <bpmn:incoming>Flow_2</bpmn:incoming>
      <bpmn:outgoing>Flow_3</bpmn:outgoing>
      <bpmn:outgoing>Flow_5</bpmn:outgoing>
    </bpmn:exclusiveGateway>
    <bpmn:task id="Investigate" name="Review source document">
      <bpmn:incoming>Flow_3</bpmn:incoming>
      <bpmn:outgoing>Flow_4</bpmn:outgoing>
    </bpmn:task>
    <bpmn:endEvent id="Flagged" name="Flagged">
      <bpmn:incoming>Flow_4</bpmn:incoming>
    </bpmn:endEvent>
    <bpmn:endEvent id="Passed" name="Reconciled">
      <bpmn:incoming>Flow_5</bpmn:incoming>
    </bpmn:endEvent>
    <bpmn:sequenceFlow id="Flow_0" sourceRef="Start" targetRef="Extract" />
    <bpmn:sequenceFlow id="Flow_1" sourceRef="Extract" targetRef="Calculate" />
    <bpmn:sequenceFlow id="Flow_2" sourceRef="Calculate" targetRef="Decision" />
    <bpmn:sequenceFlow id="Flow_3" sourceRef="Decision" targetRef="Investigate" name="Yes" />
    <bpmn:sequenceFlow id="Flow_4" sourceRef="Investigate" targetRef="Flagged" />
    <bpmn:sequenceFlow id="Flow_5" sourceRef="Decision" targetRef="Passed" name="No" />
  </bpmn:process>
  <bpmndi:BPMNDiagram id="WarehouseDiagram">
    <bpmndi:BPMNPlane id="WarehousePlane" bpmnElement="Warehouse">
      <bpmndi:BPMNShape id="Start_shape" bpmnElement="Start">
        <dc:Bounds x="70" y="150" width="36" height="36" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Extract_shape" bpmnElement="Extract">
        <dc:Bounds x="135" y="133" width="145" height="70" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Calculate_shape" bpmnElement="Calculate">
        <dc:Bounds x="315" y="133" width="150" height="70" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Decision_shape" bpmnElement="Decision">
        <dc:Bounds x="507" y="143" width="50" height="50" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Investigate_shape" bpmnElement="Investigate">
        <dc:Bounds x="605" y="133" width="170" height="70" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Flagged_shape" bpmnElement="Flagged">
        <dc:Bounds x="825" y="150" width="36" height="36" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Passed_shape" bpmnElement="Passed">
        <dc:Bounds x="514" y="259" width="36" height="36" />
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="Flow_0_edge" bpmnElement="Flow_0">
        <di:waypoint x="106" y="168" />
        <di:waypoint x="135" y="168" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Flow_1_edge" bpmnElement="Flow_1">
        <di:waypoint x="280" y="168" />
        <di:waypoint x="315" y="168" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Flow_2_edge" bpmnElement="Flow_2">
        <di:waypoint x="465" y="168" />
        <di:waypoint x="507" y="168" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Flow_3_edge" bpmnElement="Flow_3">
        <di:waypoint x="557" y="168" />
        <di:waypoint x="605" y="168" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Flow_4_edge" bpmnElement="Flow_4">
        <di:waypoint x="775" y="168" />
        <di:waypoint x="825" y="168" />
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Flow_5_edge" bpmnElement="Flow_5">
        <di:waypoint x="532" y="193" />
        <di:waypoint x="532" y="259" />
      </bpmndi:BPMNEdge>
    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>
</bpmn:definitions>