diff options
Diffstat (limited to 'bpmn')
4 files changed, 44 insertions, 61 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoHandler.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoHandler.java index e938a25fab..787453ed28 100644 --- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoHandler.java +++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoHandler.java @@ -28,9 +28,9 @@ public class CryptoHandler implements ICryptoHandler { private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL);
private static String msoKey = "aa3871669d893c7fb8abbcda31b88b4f";
- //private static String msoAaiPwd = "mso0206";
private static String msoAaiEncryptedPwd = "C1FC4A39E16419DD41DFC1212843F440";
+ @Override
public String getMsoAaiPassword() {
try {
return CryptoUtils.decrypt(msoAaiEncryptedPwd, msoKey);
@@ -41,6 +41,7 @@ public class CryptoHandler implements ICryptoHandler { }
+ @Override
public String encryptMsoPassword(String plainMsoPwd) {
try {
return CryptoUtils.encrypt(plainMsoPwd, msoKey);
@@ -50,7 +51,7 @@ public class CryptoHandler implements ICryptoHandler { }
}
-
+ @Override
public String decryptMsoPassword(String encryptedPwd) {
try {
return CryptoUtils.decrypt(encryptedPwd, msoKey);
diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/CreateCustomE2EServiceInstance.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/CreateCustomE2EServiceInstance.groovy index 7f4f78762e..73066b3722 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/CreateCustomE2EServiceInstance.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/CreateCustomE2EServiceInstance.groovy @@ -160,10 +160,10 @@ public class CreateCustomE2EServiceInstance extends AbstractServiceTaskProcessor utils.log("DEBUG", " *** sendSyncResponse *** ", isDebugEnabled) try { - String requestId = execution.getVariable("msoRequestId") + String operationId = execution.getVariable("operationId") String serviceInstanceId = execution.getVariable("serviceInstanceId") // RESTResponse for API Handler (APIH) Reply Task - String createServiceRestRequest = """{"service":{"serviceId":"${serviceInstanceId}","operationId":"${requestId}"}}""".trim() + String createServiceRestRequest = """{"service":{"serviceId":"${serviceInstanceId}","operationId":"${operationId}"}}""".trim() utils.log("DEBUG", " sendSyncResponse to APIH:" + "\n" + createServiceRestRequest, isDebugEnabled) sendWorkflowResponse(execution, 202, createServiceRestRequest) execution.setVariable("sentSyncResponse", true) @@ -337,4 +337,5 @@ public class CreateCustomE2EServiceInstance extends AbstractServiceTaskProcessor } utils.log("DEBUG", "======== COMPLETED prepareInitServiceOperationStatus Process ======== ", isDebugEnabled) } + }
\ No newline at end of file diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/CreateCustomE2EServiceInstance.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/CreateCustomE2EServiceInstance.bpmn index b9d5e2c1d2..04b47b452a 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/CreateCustomE2EServiceInstance.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/CreateCustomE2EServiceInstance.bpmn @@ -113,7 +113,7 @@ csi.sendSyncError(execution)]]></bpmn:script> <bpmn:sequenceFlow id="SequenceFlow_01umodj" sourceRef="ScriptTask_0u8o9p2" targetRef="CallActivity_1ang7q8" /> </bpmn:subProcess> <bpmn:scriptTask id="ScriptTask_0xupxj9" name="Send Sync Ack Response" scriptFormat="groovy"> - <bpmn:incoming>SequenceFlow_194rnud</bpmn:incoming> + <bpmn:incoming>SequenceFlow_081z8l2</bpmn:incoming> <bpmn:outgoing>SequenceFlow_19eilro</bpmn:outgoing> <bpmn:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.* def csi = new CreateCustomE2EServiceInstance() @@ -146,9 +146,8 @@ csi.sendSyncResponse(execution)]]></bpmn:script> <bpmn:outgoing>SequenceFlow_1euqjsp</bpmn:outgoing> <bpmn:script><![CDATA[import org.openecomp.mso.bpmn.infrastructure.scripts.* def csi= new CreateCustomE2EServiceInstance() -csi.InitServiceOperationStatus(execution)]]></bpmn:script> +csi.prepareInitServiceOperationStatus(execution)]]></bpmn:script> </bpmn:scriptTask> - <bpmn:sequenceFlow id="SequenceFlow_081z8l2" sourceRef="Task_19mxcw3" targetRef="Task_0in343a" /> <bpmn:serviceTask id="Task_19mxcw3" name="Update Service Operation Status"> <bpmn:extensionElements> <camunda:connector> @@ -171,27 +170,22 @@ csi.InitServiceOperationStatus(execution)]]></bpmn:script> <bpmn:incoming>SequenceFlow_1euqjsp</bpmn:incoming> <bpmn:outgoing>SequenceFlow_081z8l2</bpmn:outgoing> </bpmn:serviceTask> - <bpmn:sequenceFlow id="SequenceFlow_194rnud" sourceRef="Task_0in343a" targetRef="ScriptTask_0xupxj9" /> - <bpmn:scriptTask id="Task_0in343a" name="Send SDNC Service" scriptFormat="java"> - <bpmn:incoming>SequenceFlow_081z8l2</bpmn:incoming> - <bpmn:outgoing>SequenceFlow_194rnud</bpmn:outgoing> - <bpmn:script></bpmn:script> - </bpmn:scriptTask> + <bpmn:sequenceFlow id="SequenceFlow_081z8l2" sourceRef="Task_19mxcw3" targetRef="ScriptTask_0xupxj9" /> </bpmn:process> <bpmn:error id="Error_0nbdy47" name="MSOWorkflowException" errorCode="MSOWorkflowException" /> <bpmndi:BPMNDiagram id="BPMNDiagram_1"> <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateCustomE2EServiceInstance"> <bpmndi:BPMNShape id="StartEvent_00qj6ro_di" bpmnElement="StartEvent_00qj6ro"> - <dc:Bounds x="82" y="180" width="36" height="36" /> + <dc:Bounds x="-6" y="180" width="36" height="36" /> <bpmndi:BPMNLabel> - <dc:Bounds x="64" y="221" width="73" height="24" /> + <dc:Bounds x="-24" y="221" width="73" height="24" /> </bpmndi:BPMNLabel> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="SubProcess_0ka59nc_di" bpmnElement="SubProcess_0ka59nc" isExpanded="true"> <dc:Bounds x="463" y="632" width="394" height="188" /> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="CallActivity_0rhljy8_di" bpmnElement="DoCreateE2EServiceInstance"> - <dc:Bounds x="701" y="158" width="100" height="80" /> + <dc:Bounds x="751" y="158" width="100" height="80" /> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="EndEvent_0bpd6c0_di" bpmnElement="EndEvent_0bpd6c0"> <dc:Bounds x="1258" y="286" width="36" height="36" /> @@ -200,7 +194,7 @@ csi.InitServiceOperationStatus(execution)]]></bpmn:script> </bpmndi:BPMNLabel> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="ScriptTask_1s09c7d_di" bpmnElement="ScriptTask_1s09c7d"> - <dc:Bounds x="129" y="158" width="100" height="80" /> + <dc:Bounds x="115" y="158" width="100" height="80" /> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="ScriptTask_0ttvn8r_di" bpmnElement="ScriptTask_0ttvn8r"> <dc:Bounds x="1038" y="158" width="100" height="80" /> @@ -212,7 +206,7 @@ csi.InitServiceOperationStatus(execution)]]></bpmn:script> <dc:Bounds x="348" y="370" width="679" height="194" /> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="ScriptTask_0xupxj9_di" bpmnElement="ScriptTask_0xupxj9"> - <dc:Bounds x="577" y="158" width="100" height="80" /> + <dc:Bounds x="610" y="158" width="100" height="80" /> </bpmndi:BPMNShape> <bpmndi:BPMNShape id="ExclusiveGateway_0aqn64l_di" bpmnElement="ExclusiveGateway_0aqn64l" isMarkerVisible="true"> <dc:Bounds x="903" y="173" width="50" height="50" /> @@ -227,24 +221,24 @@ csi.InitServiceOperationStatus(execution)]]></bpmn:script> </bpmndi:BPMNLabel> </bpmndi:BPMNShape> <bpmndi:BPMNEdge id="SequenceFlow_0s2spoq_di" bpmnElement="SequenceFlow_0s2spoq"> - <di:waypoint xsi:type="dc:Point" x="118" y="198" /> - <di:waypoint xsi:type="dc:Point" x="129" y="198" /> + <di:waypoint xsi:type="dc:Point" x="30" y="198" /> + <di:waypoint xsi:type="dc:Point" x="115" y="198" /> <bpmndi:BPMNLabel> - <dc:Bounds x="78.5" y="177" width="90" height="12" /> + <dc:Bounds x="27.5" y="177" width="90" height="12" /> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_19eilro_di" bpmnElement="SequenceFlow_19eilro"> - <di:waypoint xsi:type="dc:Point" x="677" y="198" /> - <di:waypoint xsi:type="dc:Point" x="701" y="198" /> + <di:waypoint xsi:type="dc:Point" x="710" y="198" /> + <di:waypoint xsi:type="dc:Point" x="751" y="198" /> <bpmndi:BPMNLabel> - <dc:Bounds x="644" y="177" width="90" height="12" /> + <dc:Bounds x="685.5" y="177" width="90" height="12" /> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_0klbpxx_di" bpmnElement="SequenceFlow_0klbpxx"> - <di:waypoint xsi:type="dc:Point" x="801" y="198" /> + <di:waypoint xsi:type="dc:Point" x="851" y="198" /> <di:waypoint xsi:type="dc:Point" x="903" y="198" /> <bpmndi:BPMNLabel> - <dc:Bounds x="807" y="183" width="0" height="12" /> + <dc:Bounds x="832" y="177" width="90" height="12" /> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_0yayvrf_di" bpmnElement="SequenceFlow_0yayvrf"> @@ -255,10 +249,10 @@ csi.InitServiceOperationStatus(execution)]]></bpmn:script> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_0z4faf9_di" bpmnElement="SequenceFlow_0z4faf9"> - <di:waypoint xsi:type="dc:Point" x="229" y="198" /> - <di:waypoint xsi:type="dc:Point" x="245" y="198" /> + <di:waypoint xsi:type="dc:Point" x="215" y="198" /> + <di:waypoint xsi:type="dc:Point" x="273" y="198" /> <bpmndi:BPMNLabel> - <dc:Bounds x="192" y="177" width="90" height="12" /> + <dc:Bounds x="199" y="177" width="90" height="12" /> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_14zu6wr_di" bpmnElement="SequenceFlow_14zu6wr"> @@ -369,35 +363,25 @@ csi.InitServiceOperationStatus(execution)]]></bpmn:script> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge id="SequenceFlow_1euqjsp_di" bpmnElement="SequenceFlow_1euqjsp"> - <di:waypoint xsi:type="dc:Point" x="345" y="198" /> - <di:waypoint xsi:type="dc:Point" x="371" y="198" /> + <di:waypoint xsi:type="dc:Point" x="373" y="198" /> + <di:waypoint xsi:type="dc:Point" x="446" y="198" /> <bpmndi:BPMNLabel> - <dc:Bounds x="358" y="177" width="0" height="12" /> + <dc:Bounds x="364.5" y="177" width="90" height="12" /> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> <bpmndi:BPMNShape id="ScriptTask_1a3vwas_di" bpmnElement="Task_1tqjch6"> - <dc:Bounds x="245" y="158" width="100" height="80" /> + <dc:Bounds x="273" y="158" width="100" height="80" /> </bpmndi:BPMNShape> - <bpmndi:BPMNEdge id="SequenceFlow_081z8l2_di" bpmnElement="SequenceFlow_081z8l2"> - <di:waypoint xsi:type="dc:Point" x="497" y="198" /> - <di:waypoint xsi:type="dc:Point" x="522" y="198" /> - <bpmndi:BPMNLabel> - <dc:Bounds x="509.5" y="177" width="0" height="12" /> - </bpmndi:BPMNLabel> - </bpmndi:BPMNEdge> <bpmndi:BPMNShape id="ServiceTask_1afiuuq_di" bpmnElement="Task_19mxcw3"> - <dc:Bounds x="371" y="158" width="100" height="80" /> + <dc:Bounds x="446" y="158" width="100" height="80" /> </bpmndi:BPMNShape> - <bpmndi:BPMNEdge id="SequenceFlow_194rnud_di" bpmnElement="SequenceFlow_194rnud"> - <di:waypoint xsi:type="dc:Point" x="597" y="198" /> - <di:waypoint xsi:type="dc:Point" x="627" y="198" /> + <bpmndi:BPMNEdge id="SequenceFlow_081z8l2_di" bpmnElement="SequenceFlow_081z8l2"> + <di:waypoint xsi:type="dc:Point" x="546" y="198" /> + <di:waypoint xsi:type="dc:Point" x="610" y="198" /> <bpmndi:BPMNLabel> - <dc:Bounds x="612" y="177" width="0" height="12" /> + <dc:Bounds x="533" y="177" width="90" height="12" /> </bpmndi:BPMNLabel> </bpmndi:BPMNEdge> - <bpmndi:BPMNShape id="ScriptTask_1u5yu0n_di" bpmnElement="Task_0in343a"> - <dc:Bounds x="476" y="158" width="100" height="80" /> - </bpmndi:BPMNShape> </bpmndi:BPMNPlane> </bpmndi:BPMNDiagram> </bpmn:definitions> diff --git a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java index 5cf6f6ca05..484981c99d 100644 --- a/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java +++ b/bpmn/MSOURN-plugin/src/main/java/org/openecomp/camunda/bpmn/plugin/urnmap/resources/ProcessInstanceResource.java @@ -32,7 +32,6 @@ import org.slf4j.LoggerFactory; import org.camunda.bpm.cockpit.db.QueryParameters;
import org.camunda.bpm.cockpit.plugin.resource.AbstractPluginResource;
-import org.camunda.bpm.cockpit.db.CommandExecutor;
import org.openecomp.camunda.bpmn.plugin.urnmap.db.*;
public class ProcessInstanceResource extends AbstractPluginResource {
@@ -61,25 +60,25 @@ public class ProcessInstanceResource extends AbstractPluginResource { }
@PUT
- //public void insertNewRow(String key_, String value_)
+ //public void insertNewRow(String key, String value)
public void insertNewRow(String temp)
{
log.info("AddNewRow: XXXXXXXXXXXXXXXXX ---> " + temp);
StringTokenizer st = new StringTokenizer(temp, "|");
- String key_ = "";
- String value_ = "";
+ String key = "";
+ String value = "";
while(st.hasMoreTokens()) {
- key_ = st.nextToken();
- value_ = st.nextToken();
- System.out.println(key_ + "\t" + value_);
+ key = st.nextToken();
+ value = st.nextToken();
+ log.info(key + "\t" + value);
}
- log.info("AddNewRow: XXXXXXXXXXXXXXXXX ---> key: " + key_ + " , Value: " + value_);
+ log.info("AddNewRow: XXXXXXXXXXXXXXXXX ---> key: " + key + " , Value: " + value);
URNData nRow = new URNData();
nRow.setVer_("1");
- nRow.setURNName(key_);
- nRow.setURNValue(value_);
+ nRow.setURNName(key);
+ nRow.setURNValue(value);
getQueryService().executeQuery("cockpit.urnMap.insertNewRow", nRow, URNData.class);
@@ -87,14 +86,12 @@ public class ProcessInstanceResource extends AbstractPluginResource { }
@POST
- // public void getPersistData(List<URNData > myList) {
public void getPersistData(URNData d) {
log.info("getPersistData: UrnName: " + d.getURNName() + " , URNValue: " + d.getURNValue() );
getQueryService().executeQuery("cockpit.urnMap.persistURNData", d, URNData.class);
- //getQueryService().executeQuery("cockpit.sample.persistURNData", d, ProcessInstanceCountDto.class);
-
+
log.info("XXXXXXXXXX - END - XXXXXXXXXXXXXXX");
}
|