diff options
author | Gary Wu <gary.i.wu@huawei.com> | 2017-05-09 12:41:43 -0700 |
---|---|---|
committer | Gary Wu <gary.i.wu@huawei.com> | 2017-05-09 12:47:05 -0700 |
commit | a4ade73cdb768ee15bc8dd032904743f84326ee2 (patch) | |
tree | b803590f1ccfe9b2588d70edd59ab462b7ed84c6 /bpmn/MSOInfrastructureBPMN/src | |
parent | b1e5734ef566af5d49ba17d05ca0ab7b56d6666d (diff) |
Refactor WorkflowAsyncResource
Change-Id: I794b606687343851f71d63ac055ed1898320216a
Signed-off-by: Gary Wu <gary.i.wu@huawei.com>
Diffstat (limited to 'bpmn/MSOInfrastructureBPMN/src')
-rw-r--r-- | bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/service/WorkflowAsyncInfrastructureResource.java | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/service/WorkflowAsyncInfrastructureResource.java b/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/service/WorkflowAsyncInfrastructureResource.java index 09454f0876..0cc81bf0c6 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/service/WorkflowAsyncInfrastructureResource.java +++ b/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/service/WorkflowAsyncInfrastructureResource.java @@ -40,11 +40,7 @@ import org.openecomp.mso.bpmn.common.workflow.service.WorkflowAsyncResource; @Path("/async")
public class WorkflowAsyncInfrastructureResource extends WorkflowAsyncResource {
- protected ProcessEngineServices getProcessEngineServices() {
- if (pes4junit == null) {
- return ProcessEngines.getProcessEngine("infrastructure");
- } else {
- return pes4junit;
- }
- }
+ protected ProcessEngineServices getProcessEngineServices() {
+ return pes4junit.orElse(ProcessEngines.getProcessEngine("infrastructure"));
+ }
}
|