summaryrefslogtreecommitdiffstats
path: root/bpmn/so-bpmn-infrastructure-common
diff options
context:
space:
mode:
authorMarcus Williams <marcus.williams@intel.com>2018-08-13 22:32:14 +0000
committerGerrit Code Review <gerrit@onap.org>2018-08-13 22:32:14 +0000
commita75f148c46a932796312dd83c9b12d30e415d2e3 (patch)
treee1a1a54a41e472a02eb2d45f163f499aaa41e24d /bpmn/so-bpmn-infrastructure-common
parentfee9fc95c8b56495463cd2e909b562a226d329f0 (diff)
parent4f2e01ce0175434240f523e9722f1cd236c7afde (diff)
Merge "Fix for NullPointerException in Pnf"
Diffstat (limited to 'bpmn/so-bpmn-infrastructure-common')
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/InformDmaapClient.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/InformDmaapClient.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/InformDmaapClient.java
index bb490a06e4..61b1ca4cae 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/InformDmaapClient.java
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/pnf/delegate/InformDmaapClient.java
@@ -20,6 +20,7 @@
package org.onap.so.bpmn.infrastructure.pnf.delegate;
+import org.camunda.bpm.engine.RuntimeService;
import org.camunda.bpm.engine.delegate.DelegateExecution;
import org.camunda.bpm.engine.delegate.JavaDelegate;
import org.onap.so.bpmn.infrastructure.pnf.dmaap.DmaapClient;
@@ -30,12 +31,15 @@ public class InformDmaapClient implements JavaDelegate {
private DmaapClient dmaapClient;
@Override
- public void execute(DelegateExecution execution) throws Exception {
+ public void execute(DelegateExecution execution) {
String correlationId = (String) execution.getVariable(ExecutionVariableNames.CORRELATION_ID);
- dmaapClient.registerForUpdate(correlationId, () -> execution.getProcessEngineServices().getRuntimeService()
+ RuntimeService runtimeService = execution.getProcessEngineServices().getRuntimeService();
+ dmaapClient.registerForUpdate(correlationId, () ->
+ runtimeService
.createMessageCorrelation("WorkflowMessage")
.processInstanceBusinessKey(execution.getProcessBusinessKey())
- .correlateWithResult());
+ .correlateWithResult()
+ );
}
@Autowired