Community
The log says "<processid> has been deleted" when setting statuskey by a environment variable and using a timer delay
about 2 months ago by Dennis
This flow:
will give the result " has been deleted" in the log:
Setting the statuskey to the same value, "complete", by a static value instead of a variable:
will not give this problem:
Removing the delay:
will not give this problem either:
Could you please confirm if this is a bug, when it could be fixed and any possible workarounds in the meantime?
<?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:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_0sdny8d" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="5.24.0">
<bpmn:collaboration id="Collaboration_1vlu0n3">
<bpmn:participant id="ParticipantNameParticipant" name="ParticipantName" processRef="put-process-name-here" />
</bpmn:collaboration>
<bpmn:process id="put-process-name-here" name="ProcessName" isExecutable="true">
<bpmn:laneSet id="LaneSet_02o4jdr">
<bpmn:lane id="AllSystemsLane" name="All systems">
<bpmn:flowNodeRef>StartStartEvent</bpmn:flowNodeRef>
<bpmn:flowNodeRef>SetStatuskeyToCompleteTask</bpmn:flowNodeRef>
<bpmn:flowNodeRef>EndEndEvent</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Wait2SecondsEvent</bpmn:flowNodeRef>
</bpmn:lane>
</bpmn:laneSet>
<bpmn:startEvent id="StartStartEvent" name="Start">
<bpmn:outgoing>Flow_0wk332j</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:sequenceFlow id="Flow_0wk332j" sourceRef="StartStartEvent" targetRef="SetStatuskeyToCompleteTask" />
<bpmn:sequenceFlow id="Flow_1qg3sr2" sourceRef="SetStatuskeyToCompleteTask" targetRef="Wait2SecondsEvent" />
<bpmn:scriptTask id="SetStatuskeyToCompleteTask" name="Set statuskey to "complete"" scriptFormat="js">
<bpmn:extensionElements>
<camunda:inputOutput>
<camunda:outputParameter name="status">
<camunda:map>
<camunda:entry key="statuskey">${environment.variables.myvar}</camunda:entry>
</camunda:map>
</camunda:outputParameter>
</camunda:inputOutput>
<camunda:executionListener event="end">
<camunda:script scriptFormat="js">console.log(`Just to doublecheck, environment.variables.myvar is set to "${environment.variables.myvar}"`)
next()</camunda:script>
</camunda:executionListener>
</bpmn:extensionElements>
<bpmn:incoming>Flow_0wk332j</bpmn:incoming>
<bpmn:outgoing>Flow_1qg3sr2</bpmn:outgoing>
<bpmn:script>environment.variables.myvar = "complete"
next()</bpmn:script>
</bpmn:scriptTask>
<bpmn:endEvent id="EndEndEvent" name="End">
<bpmn:incoming>Flow_053loni</bpmn:incoming>
</bpmn:endEvent>
<bpmn:intermediateCatchEvent id="Wait2SecondsEvent" name="Wait 2 seconds">
<bpmn:incoming>Flow_1qg3sr2</bpmn:incoming>
<bpmn:outgoing>Flow_053loni</bpmn:outgoing>
<bpmn:timerEventDefinition id="TimerEventDefinition_1kjsnj7">
<bpmn:timeDuration xsi:type="bpmn:tFormalExpression">PT2S</bpmn:timeDuration>
</bpmn:timerEventDefinition>
</bpmn:intermediateCatchEvent>
<bpmn:sequenceFlow id="Flow_053loni" sourceRef="Wait2SecondsEvent" targetRef="EndEndEvent" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Collaboration_1vlu0n3">
<bpmndi:BPMNShape id="Participant_1b38ks9_di" bpmnElement="ParticipantNameParticipant" isHorizontal="true">
<dc:Bounds x="160" y="80" width="640" height="180" />
<bpmndi:BPMNLabel />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Lane_0ougcvv_di" bpmnElement="AllSystemsLane" isHorizontal="true">
<dc:Bounds x="190" y="80" width="610" height="180" />
<bpmndi:BPMNLabel />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartStartEvent">
<dc:Bounds x="262" y="152" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="270" y="195" width="25" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_1wlnfln_di" bpmnElement="SetStatuskeyToCompleteTask">
<dc:Bounds x="360" y="130" width="100" height="80" />
<bpmndi:BPMNLabel />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_0ynfbyi_di" bpmnElement="EndEndEvent">
<dc:Bounds x="712" y="152" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="721" y="195" width="20" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="BPMNShape_0yip7wl" bpmnElement="Wait2SecondsEvent">
<dc:Bounds x="602" y="152" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="586" y="195" width="75" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Flow_0wk332j_di" bpmnElement="Flow_0wk332j">
<di:waypoint x="298" y="170" />
<di:waypoint x="360" y="170" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1qg3sr2_di" bpmnElement="Flow_1qg3sr2">
<di:waypoint x="460" y="170" />
<di:waypoint x="602" y="170" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_053loni_di" bpmnElement="Flow_053loni">
<di:waypoint x="638" y="170" />
<di:waypoint x="712" y="170" />
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>