You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
hetzner-ansible/smardigo/backup/process/primary-process.bpmn

305 lines
17 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="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:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:bioc="http://bpmn.io/schema/bpmn/biocolor/1.0" id="sample-diagram" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.12.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:signal id="Signal_0kz05aq" name="antrag-abgeschlossen-${execution.getProcessInstanceId()}" />
<bpmn2:message id="Message_13oyyv2" name="action-executed-${execution.getVariable(&#39;smardigoManagementAction&#39;)}" />
<bpmn2:collaboration id="Collaboration_0oahy0i">
<bpmn2:participant id="Participant_19lpjee" name="Primary Process" processRef="primary-process" />
<bpmn2:participant id="Participant_138furn" name="Smardigo Management Action" processRef="smardigo-management-action" />
<bpmn2:participant id="Participant_1jw669n" name="Smardigo Management Message" processRef="smardigo-management-message" />
</bpmn2:collaboration>
<bpmn2:process id="primary-process" name="Primary Process" isExecutable="true" camunda:candidateStarterGroups="administrator">
<bpmn2:startEvent id="Event_0wqvypp">
<bpmn2:outgoing>Flow_1a8vxf0</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:sequenceFlow id="Flow_0oc7f69" sourceRef="Event_1ho1j80" targetRef="Activity_1t227a4" />
<bpmn2:sequenceFlow id="Flow_1a8vxf0" sourceRef="Event_0wqvypp" targetRef="Activity_12c4494" />
<bpmn2:endEvent id="Event_14fmnl2">
<bpmn2:incoming>Flow_0ufs5lg</bpmn2:incoming>
</bpmn2:endEvent>
<bpmn2:intermediateThrowEvent id="Event_1l1qtec" name="set state &#34;done&#34;" camunda:asyncAfter="true">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:outputParameter name="vorgang_status">${999}</camunda:outputParameter>
<camunda:outputParameter name="vorgang_status_text">done</camunda:outputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_0htljqr</bpmn2:incoming>
<bpmn2:outgoing>Flow_0ufs5lg</bpmn2:outgoing>
</bpmn2:intermediateThrowEvent>
<bpmn2:callActivity id="Activity_1t227a4" name="Backup erstellen" calledElement="smardigo-management-action">
<bpmn2:extensionElements>
<camunda:in businessKey="#{execution.processBusinessKey}" />
<camunda:in variables="all" />
<camunda:in sourceExpression="create-remote-database-backup" target="smardigoManagementAction" />
<camunda:in sourceExpression="Backup erstellen" target="comment" />
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_0oc7f69</bpmn2:incoming>
<bpmn2:outgoing>Flow_0htljqr</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:sequenceFlow id="Flow_0ufs5lg" sourceRef="Event_1l1qtec" targetRef="Event_14fmnl2" />
<bpmn2:sequenceFlow id="Flow_0htljqr" sourceRef="Activity_1t227a4" targetRef="Event_1l1qtec" />
<bpmn2:intermediateThrowEvent id="Event_1ho1j80" name="set state &#34;new&#34;" camunda:asyncAfter="true">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:outputParameter name="vorgang_status">${10}</camunda:outputParameter>
<camunda:outputParameter name="vorgang_status_text">new</camunda:outputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_1vjr74e</bpmn2:incoming>
<bpmn2:outgoing>Flow_0oc7f69</bpmn2:outgoing>
</bpmn2:intermediateThrowEvent>
<bpmn2:sequenceFlow id="Flow_1vjr74e" sourceRef="Activity_12c4494" targetRef="Event_1ho1j80" />
<bpmn2:task id="Activity_12c4494" name="Defaultwerte setzen">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:outputParameter name="progress_current">${0}</camunda:outputParameter>
<camunda:outputParameter name="progress_max">${1}</camunda:outputParameter>
<camunda:outputParameter name="cluster">
<camunda:map>
<camunda:entry key="stage">${envStage}</camunda:entry>
<camunda:entry key="name" />
<camunda:entry key="size">${1}</camunda:entry>
<camunda:entry key="service">connect</camunda:entry>
</camunda:map>
</camunda:outputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_1a8vxf0</bpmn2:incoming>
<bpmn2:outgoing>Flow_1vjr74e</bpmn2:outgoing>
</bpmn2:task>
</bpmn2:process>
<bpmn2:process id="smardigo-management-action" name="Smardigo Management Action" isExecutable="true">
<bpmn2:startEvent id="Event_01o224p" camunda:formKey="simple-connect-create">
<bpmn2:outgoing>Flow_1o2xasq</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:scriptTask id="Activity_12re8b9" name="ansible-start.groovy" scriptFormat="groovy" camunda:resource="ansible-start.groovy">
<bpmn2:incoming>Flow_1o2xasq</bpmn2:incoming>
<bpmn2:outgoing>Flow_02t94f3</bpmn2:outgoing>
</bpmn2:scriptTask>
<bpmn2:callActivity id="Activity_112dgam" name="Management Benachrichtigung senden" calledElement="smardigo-management-message">
<bpmn2:extensionElements>
<camunda:in businessKey="#{execution.processBusinessKey}" />
<camunda:in variables="all" />
<camunda:in sourceExpression="Neue Aufgabe" target="activityTitle" />
<camunda:in sourceExpression="${smardigoManagementAction}" target="activitySubtitle" />
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_02t94f3</bpmn2:incoming>
<bpmn2:outgoing>Flow_037h9ne</bpmn2:outgoing>
</bpmn2:callActivity>
<bpmn2:task id="Activity_0l65eu5" name="AWX Job-Template-ID auslesen">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:outputParameter name="job_template_id">
<camunda:script scriptFormat="groovy">datasources.query('awx-job-templates').processScope(contextScopeId, contextProcessId).parameters([name:smardigoManagementAction]).list()[0]['id'];</camunda:script>
</camunda:outputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_037h9ne</bpmn2:incoming>
<bpmn2:outgoing>Flow_0itcfsg</bpmn2:outgoing>
</bpmn2:task>
<bpmn2:task id="Activity_0sfkswg" name="AWX REST-Parameter erzeugen">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:outputParameter name="awxPath">/api/v2/job_templates/${job_template_id}/launch/</camunda:outputParameter>
<camunda:outputParameter name="extra_vars">
<camunda:script scriptFormat="groovy" resource="create-awx-paramaters.groovy" />
</camunda:outputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_0itcfsg</bpmn2:incoming>
<bpmn2:outgoing>Flow_0a10mmp</bpmn2:outgoing>
</bpmn2:task>
<bpmn2:intermediateCatchEvent id="Event_0sktyab" name="Ausführung der Aktion abwarten">
<bpmn2:incoming>Flow_042nfag</bpmn2:incoming>
<bpmn2:outgoing>Flow_1wct7o1</bpmn2:outgoing>
<bpmn2:messageEventDefinition id="MessageEventDefinition_0zacgpp" messageRef="Message_13oyyv2" />
</bpmn2:intermediateCatchEvent>
<bpmn2:scriptTask id="Activity_0cy8ilh" name="ansible-end.groovy" scriptFormat="groovy" camunda:resource="ansible-end.groovy">
<bpmn2:incoming>Flow_1wct7o1</bpmn2:incoming>
<bpmn2:outgoing>Flow_0cnh8iv</bpmn2:outgoing>
</bpmn2:scriptTask>
<bpmn2:endEvent id="Event_1k0agtb">
<bpmn2:incoming>Flow_0cnh8iv</bpmn2:incoming>
<bpmn2:terminateEventDefinition id="TerminateEventDefinition_0z7lpih" />
</bpmn2:endEvent>
<bpmn2:serviceTask id="Activity_0m6rbdo" name="AWX Provisionierung starten" camunda:delegateExpression="${rest.post(&#39;awx&#39;, awxPath).responseJSONObject(&#39;awxResponse&#39;).bodyJSONMap(awxRequestBody)}">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:inputParameter name="awxRequestBody">
<camunda:map>
<camunda:entry key="extra_vars">${extra_vars}</camunda:entry>
</camunda:map>
</camunda:inputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_0a10mmp</bpmn2:incoming>
<bpmn2:outgoing>Flow_042nfag</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:sequenceFlow id="Flow_042nfag" sourceRef="Activity_0m6rbdo" targetRef="Event_0sktyab" />
<bpmn2:sequenceFlow id="Flow_0itcfsg" sourceRef="Activity_0l65eu5" targetRef="Activity_0sfkswg" />
<bpmn2:sequenceFlow id="Flow_0cnh8iv" sourceRef="Activity_0cy8ilh" targetRef="Event_1k0agtb" />
<bpmn2:sequenceFlow id="Flow_1wct7o1" sourceRef="Event_0sktyab" targetRef="Activity_0cy8ilh" />
<bpmn2:sequenceFlow id="Flow_02t94f3" sourceRef="Activity_12re8b9" targetRef="Activity_112dgam" />
<bpmn2:sequenceFlow id="Flow_1o2xasq" sourceRef="Event_01o224p" targetRef="Activity_12re8b9" />
<bpmn2:sequenceFlow id="Flow_037h9ne" sourceRef="Activity_112dgam" targetRef="Activity_0l65eu5" />
<bpmn2:sequenceFlow id="Flow_0a10mmp" sourceRef="Activity_0sfkswg" targetRef="Activity_0m6rbdo" />
</bpmn2:process>
<bpmn2:process id="smardigo-management-message" name="Smardigo Management Message" isExecutable="true">
<bpmn2:startEvent id="Event_0cntm51" camunda:formKey="simple-connect-create">
<bpmn2:outgoing>Flow_1nplu24</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:serviceTask id="Activity_00iw76a" name="MS-Teams Benachrichtigung senden" camunda:delegateExpression="${rest.post(&#39;teams&#39;, &#39;/&#39;).responseJSONObject(&#39;teamsResponse&#39;).bodyJSONMap(teamsRequestBody)}">
<bpmn2:extensionElements>
<camunda:inputOutput>
<camunda:inputParameter name="teamsRequestBody">
<camunda:script scriptFormat="groovy" resource="create-teams-message.groovy" />
</camunda:inputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>Flow_1nplu24</bpmn2:incoming>
<bpmn2:outgoing>Flow_1tye2db</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:endEvent id="Event_0t0mo04">
<bpmn2:incoming>Flow_1tye2db</bpmn2:incoming>
<bpmn2:terminateEventDefinition id="TerminateEventDefinition_1ajgh7z" />
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="Flow_1nplu24" sourceRef="Event_0cntm51" targetRef="Activity_00iw76a" />
<bpmn2:sequenceFlow id="Flow_1tye2db" sourceRef="Activity_00iw76a" targetRef="Event_0t0mo04" />
</bpmn2:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Collaboration_0oahy0i">
<bpmndi:BPMNShape id="Participant_19lpjee_di" bpmnElement="Participant_19lpjee" isHorizontal="true">
<dc:Bounds x="160" y="470" width="1710" height="590" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Flow_1a8vxf0_di" bpmnElement="Flow_1a8vxf0">
<di:waypoint x="398" y="690" />
<di:waypoint x="450" y="690" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0oc7f69_di" bpmnElement="Flow_0oc7f69">
<di:waypoint x="698" y="690" />
<di:waypoint x="780" y="690" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0ufs5lg_di" bpmnElement="Flow_0ufs5lg">
<di:waypoint x="948" y="690" />
<di:waypoint x="982" y="690" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0htljqr_di" bpmnElement="Flow_0htljqr">
<di:waypoint x="880" y="690" />
<di:waypoint x="912" y="690" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1vjr74e_di" bpmnElement="Flow_1vjr74e">
<di:waypoint x="550" y="690" />
<di:waypoint x="662" y="690" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="Event_04q3ydu_di" bpmnElement="Event_0wqvypp">
<dc:Bounds x="362" y="672" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_14fmnl2_di" bpmnElement="Event_14fmnl2">
<dc:Bounds x="982" y="672" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_1l1qtec_di" bpmnElement="Event_1l1qtec">
<dc:Bounds x="912" y="672" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="893" y="718" width="77" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_1t227a4_di" bpmnElement="Activity_1t227a4" bioc:stroke="rgb(67, 160, 71)" bioc:fill="rgb(200, 230, 201)">
<dc:Bounds x="780" y="650" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_1ho1j80_di" bpmnElement="Event_1ho1j80">
<dc:Bounds x="662" y="672" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="645" y="718" width="73" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_12c4494_di" bpmnElement="Activity_12c4494">
<dc:Bounds x="450" y="650" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Participant_138furn_di" bpmnElement="Participant_138furn" isHorizontal="true">
<dc:Bounds x="160" y="80" width="1320" height="380" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Flow_0a10mmp_di" bpmnElement="Flow_0a10mmp">
<di:waypoint x="900" y="270" />
<di:waypoint x="960" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_037h9ne_di" bpmnElement="Flow_037h9ne">
<di:waypoint x="580" y="270" />
<di:waypoint x="640" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1o2xasq_di" bpmnElement="Flow_1o2xasq">
<di:waypoint x="248" y="270" />
<di:waypoint x="320" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_02t94f3_di" bpmnElement="Flow_02t94f3">
<di:waypoint x="420" y="270" />
<di:waypoint x="480" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1wct7o1_di" bpmnElement="Flow_1wct7o1">
<di:waypoint x="1158" y="270" />
<di:waypoint x="1220" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0cnh8iv_di" bpmnElement="Flow_0cnh8iv">
<di:waypoint x="1320" y="270" />
<di:waypoint x="1382" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0itcfsg_di" bpmnElement="Flow_0itcfsg">
<di:waypoint x="740" y="270" />
<di:waypoint x="800" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_042nfag_di" bpmnElement="Flow_042nfag">
<di:waypoint x="1060" y="270" />
<di:waypoint x="1122" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="Event_01o224p_di" bpmnElement="Event_01o224p">
<dc:Bounds x="212" y="252" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_12re8b9_di" bpmnElement="Activity_12re8b9">
<dc:Bounds x="320" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_112dgam_di" bpmnElement="Activity_112dgam" bioc:stroke="rgb(67, 160, 71)" bioc:fill="rgb(200, 230, 201)">
<dc:Bounds x="480" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0l65eu5_di" bpmnElement="Activity_0l65eu5">
<dc:Bounds x="640" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0sfkswg_di" bpmnElement="Activity_0sfkswg">
<dc:Bounds x="800" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_0sktyab_di" bpmnElement="Event_0sktyab">
<dc:Bounds x="1122" y="252" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="1103" y="296" width="79" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0cy8ilh_di" bpmnElement="Activity_0cy8ilh">
<dc:Bounds x="1220" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_1k0agtb_di" bpmnElement="Event_1k0agtb">
<dc:Bounds x="1382" y="252" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0m6rbdo_di" bpmnElement="Activity_0m6rbdo">
<dc:Bounds x="960" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Participant_1jw669n_di" bpmnElement="Participant_1jw669n" isHorizontal="true">
<dc:Bounds x="1500" y="80" width="370" height="380" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Flow_1tye2db_di" bpmnElement="Flow_1tye2db">
<di:waypoint x="1750" y="270" />
<di:waypoint x="1792" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1nplu24_di" bpmnElement="Flow_1nplu24">
<di:waypoint x="1598" y="270" />
<di:waypoint x="1650" y="270" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="Event_0cntm51_di" bpmnElement="Event_0cntm51">
<dc:Bounds x="1562" y="252" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_00iw76a_di" bpmnElement="Activity_00iw76a" bioc:stroke="black" bioc:fill="white">
<dc:Bounds x="1650" y="230" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_0t0mo04_di" bpmnElement="Event_0t0mo04">
<dc:Bounds x="1792" y="252" width="36" height="36" />
</bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>