<?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:camunda="http://activiti.org/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd" id="_5V2IcL4gEeOQo_IRkjDF6w" exporter="camunda modeler" exporterVersion="2.5.0" targetNamespace="http://activiti.org/bpmn">
<bpmn2:process id="approve-loan" name="Loan Approval" isExecutable="true">
<bpmn2:startEvent id="StartEvent_1" camunda:formKey="embedded:app:forms/request-loan.html" name="Loan Request
Received">
<bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:userTask id="UserTask_1" camunda:assignee="john" camunda:formKey="embedded:app:forms/approve-loan.html" name="Approve
Loan">
<bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
</bpmn2:userTask>
<bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="StartEvent_1" targetRef="UserTask_1"/>
<bpmn2:sequenceFlow id="SequenceFlow_2" name="" sourceRef="UserTask_1" targetRef="ServiceTask_3"/>
<bpmn2:serviceTask id="ServiceTask_3" camunda:class="org.camunda.bpm.getstarted.loanapproval.ProcessRequestDelegate" name="Process
Request">
<bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="ServiceTask_1" name="Get Weather Forecast (Soap)">
<bpmn2:extensionElements>
<camunda:connector>
<camunda:connectorId>soap-http-connector</camunda:connectorId>
<camunda:inputOutput>
<camunda:inputParameter name="url">http://www.webservicex.net/globalweather.asmx</camunda:inputParameter>
<camunda:inputParameter name="payload">
<camunda:script scriptFormat="freemarker" resource="soapEnvelope.ftl"/>
</camunda:inputParameter>
<camunda:inputParameter name="headers">
<camunda:map>
<camunda:entry key="Content-Type"><![CDATA[application/soap+xml;charset=UTF-8;action="http://www.webserviceX.NET/GetWeather"]]></camunda:entry>
</camunda:map>
</camunda:inputParameter>
<camunda:outputParameter name="forecast">
<![CDATA[
${S(response)
.childElement("Body")
.childElement("http://www.webserviceX.NET", "GetWeatherResponse")
.childElement("GetWeatherResult")
.textContent()}
]]>
</camunda:outputParameter>
</camunda:inputOutput>
</camunda:connector>
<camunda:inputOutput>
<camunda:outputParameter name="temperature">
<camunda:script scriptFormat="Javascript" resource="parseTemperature.js"/>
</camunda:outputParameter>
</camunda:inputOutput>
</bpmn2:extensionElements>
<bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="ServiceTask_3" targetRef="ServiceTask_1"/>
<bpmn2:exclusiveGateway id="ExclusiveGateway_1">
<bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>
<bpmn2:outgoing>SequenceFlow_9</bpmn2:outgoing>
</bpmn2:exclusiveGateway>
<bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="ServiceTask_1" targetRef="ExclusiveGateway_1"/>
<bpmn2:userTask id="UserTask_3" name="Pack for cold weather">
<bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
</bpmn2:userTask>
<bpmn2:userTask id="UserTask_2" name="Pack for warm weather">
<bpmn2:incoming>SequenceFlow_9</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
</bpmn2:userTask>
<bpmn2:endEvent id="EndEvent_1" name="Loan Request
Approved">
<bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="UserTask_3" targetRef="EndEvent_1"/>
<bpmn2:endEvent id="EndEvent_2">
<bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="UserTask_2" targetRef="EndEvent_2"/>
<bpmn2:sequenceFlow id="SequenceFlow_8" name="temperature below 18" sourceRef="ExclusiveGateway_1" targetRef="UserTask_3">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression" camunda:resource="${temperature < 18}"/>
</bpmn2:sequenceFlow>
<bpmn2:sequenceFlow id="SequenceFlow_9" name="temperature above 18" sourceRef="ExclusiveGateway_1" targetRef="UserTask_2">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression" camunda:resource="${temperature >= 18}"/>
</bpmn2:sequenceFlow>
</bpmn2:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="approve-loan">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1">
<dc:Bounds height="36.0" width="36.0" x="158.0" y="215.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_UserTask_2" bpmnElement="UserTask_1">
<dc:Bounds height="80.0" width="100.0" x="244.0" y="193.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_2" targetElement="_BPMNShape_UserTask_2">
<di:waypoint xsi:type="dc:Point" x="194.0" y="233.0"/>
<di:waypoint xsi:type="dc:Point" x="244.0" y="233.0"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_2" bpmnElement="EndEvent_1">
<dc:Bounds height="36.0" width="36.0" x="881.0" y="324.0"/>
<bpmndi:BPMNLabel>
<dc:Bounds height="44.0" width="119.0" x="840.0" y="365.0"/>
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_2" sourceElement="_BPMNShape_UserTask_2" targetElement="_BPMNShape_ServiceTask_4">
<di:waypoint xsi:type="dc:Point" x="344.0" y="233.0"/>
<di:waypoint xsi:type="dc:Point" x="385.0" y="233.0"/>
<bpmndi:BPMNLabel>
<dc:Bounds height="6.0" width="6.0" x="366.0" y="233.0"/>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ServiceTask_4" bpmnElement="ServiceTask_3">
<dc:Bounds height="80.0" width="100.0" x="385.0" y="193.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ServiceTask_5" bpmnElement="ServiceTask_1">
<dc:Bounds height="80.0" width="100.0" x="528.0" y="193.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ServiceTask_4" targetElement="_BPMNShape_ServiceTask_5">
<di:waypoint xsi:type="dc:Point" x="485.0" y="233.0"/>
<di:waypoint xsi:type="dc:Point" x="528.0" y="233.0"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ExclusiveGateway_2" bpmnElement="ExclusiveGateway_1" isMarkerVisible="true">
<dc:Bounds height="50.0" width="50.0" x="678.0" y="208.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_4" sourceElement="_BPMNShape_ServiceTask_5" targetElement="_BPMNShape_ExclusiveGateway_2">
<di:waypoint xsi:type="dc:Point" x="628.0" y="233.0"/>
<di:waypoint xsi:type="dc:Point" x="678.0" y="233.0"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_UserTask_3" bpmnElement="UserTask_2">
<dc:Bounds height="80.0" width="100.0" x="744.0" y="114.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_UserTask_4" bpmnElement="UserTask_3">
<dc:Bounds height="80.0" width="100.0" x="741.0" y="298.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_UserTask_4" targetElement="_BPMNShape_EndEvent_2">
<di:waypoint xsi:type="dc:Point" x="841.0" y="338.0"/>
<di:waypoint xsi:type="dc:Point" x="861.0" y="338.0"/>
<di:waypoint xsi:type="dc:Point" x="861.0" y="342.0"/>
<di:waypoint xsi:type="dc:Point" x="881.0" y="342.0"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_EndEvent_3" bpmnElement="EndEvent_2">
<dc:Bounds height="36.0" width="36.0" x="894.0" y="136.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_7" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_UserTask_3" targetElement="_BPMNShape_EndEvent_3">
<di:waypoint xsi:type="dc:Point" x="844.0" y="154.0"/>
<di:waypoint xsi:type="dc:Point" x="894.0" y="154.0"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="_BPMNShape_ExclusiveGateway_2" targetElement="_BPMNShape_UserTask_4">
<di:waypoint xsi:type="dc:Point" x="703.0" y="258.0"/>
<di:waypoint xsi:type="dc:Point" x="703.0" y="338.0"/>
<di:waypoint xsi:type="dc:Point" x="741.0" y="338.0"/>
<bpmndi:BPMNLabel>
<dc:Bounds height="25.0" width="162.0" x="568.0" y="354.0"/>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_9" bpmnElement="SequenceFlow_9" sourceElement="_BPMNShape_ExclusiveGateway_2" targetElement="_BPMNShape_UserTask_3">
<di:waypoint xsi:type="dc:Point" x="703.0" y="208.0"/>
<di:waypoint xsi:type="dc:Point" x="703.0" y="154.0"/>
<di:waypoint xsi:type="dc:Point" x="744.0" y="154.0"/>
<bpmndi:BPMNLabel>
<dc:Bounds height="25.0" width="164.0" x="582.0" y="120.0"/>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
<camunda:outputParameter name="forecast">
<![CDATA[
${S(response)
.childElement("Body")
.childElement("http://www.webserviceX.NET", "GetWeatherResponse")
.childElement("GetWeatherResult")
.textContent()}
]]>
</camunda:outputParameter>
to
<camunda:outputParameter name="forecast">
<![CDATA[
${XML(response)
.childElement("Body")
.childElement("http://www.webserviceX.NET", "GetWeatherResponse")
.childElement("GetWeatherResult")
.textContent()}
]]>
</camunda:outputParameter>
...
--
You received this message because you are subscribed to a topic in the Google Groups "camunda BPM users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/camunda-bpm-users/dEIG6qbMEUk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to camunda-bpm-us...@googlegroups.com.
To post to this group, send email to camunda-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/camunda-bpm-users/638ddfe3-435a-4bb5-a67e-484a45e9960b%40googlegroups.com.
<camunda:outputParameter name="forecast">
<![CDATA[${response}]]>
</camunda:outputParameter>
This will put the raw response XML into the variable "forecast" and you can inspect its content, for example in a following Java delegate. Could you please post the content of the "forecast" variable in this case?...
--
You received this message because you are subscribed to a topic in the Google Groups "camunda BPM users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/camunda-bpm-users/dEIG6qbMEUk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to camunda-bpm-us...@googlegroups.com.
To post to this group, send email to camunda-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/camunda-bpm-users/fa4d71c3-4beb-4fdd-a318-c9a4ef8a647c%40googlegroups.com.
--
You received this message because you are subscribed to a topic in the Google Groups "camunda BPM users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/camunda-bpm-users/dEIG6qbMEUk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to camunda-bpm-us...@googlegroups.com.
To post to this group, send email to camunda-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/camunda-bpm-users/575ec509-f704-4f79-bb00-2772f3b4cb79%40googlegroups.com.
--
You received this message because you are subscribed to a topic in the Google Groups "camunda BPM users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/camunda-bpm-users/dEIG6qbMEUk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to camunda-bpm-us...@googlegroups.com.
To post to this group, send email to camunda-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/camunda-bpm-users/676cca3e-d733-4f68-94cd-e31de384daea%40googlegroups.com.
var regex = /\((-?\d+) C\)/;
<bpmn2:sequenceFlow id="SequenceFlow_8" name="temperature below 18" sourceRef="ExclusiveGateway_1" targetRef="UserTask_3">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[${temperature < 18}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
<bpmn2:sequenceFlow id="SequenceFlow_9" name="temperature above 18" sourceRef="ExclusiveGateway_1" targetRef="UserTask_2">
<bpmn2:conditionExpression xsi:type="bpmn2:tFormalExpression"><![CDATA[${temperature >= 18}]]></bpmn2:conditionExpression>
</bpmn2:sequenceFlow>
--
You received this message because you are subscribed to a topic in the Google Groups "camunda BPM users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/camunda-bpm-users/dEIG6qbMEUk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to camunda-bpm-us...@googlegroups.com.
To post to this group, send email to camunda-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/camunda-bpm-users/83c3f75b-ba6d-4f15-9e89-d4c67589e8de%40googlegroups.com.