From 5442c270ad879e4db33b2759b15bf46111af2fa7 Mon Sep 17 00:00:00 2001 From: "Benjamin, Max (mb388a)" Date: Thu, 14 Feb 2019 19:52:29 -0500 Subject: [PATCH] updated camunda springboot version Added required unimplemented methods to classes Change-Id: I1ab6333582f2f09c6c363786c8168fdf54936bf8 Issue-ID: SO-1512 Signed-off-by: Benjamin, Max (mb388a) --- bpmn/pom.xml | 4 +- .../client/builder/AbstractBuilderTest.java | 71 +++++++++++++--------- .../builder/NetworkRpcInputEntityBuilderTest.java | 21 +++++-- .../builder/ServiceRpcInputEntityBuilderTest.java | 21 +++++-- bpmn/so-bpmn-tasks/src/test/resources/schema.sql | 11 +++- mso-api-handlers/mso-api-handler-infra/pom.xml | 4 +- pom.xml | 30 ++++----- 7 files changed, 104 insertions(+), 58 deletions(-) diff --git a/bpmn/pom.xml b/bpmn/pom.xml index e28bedda99..df68017f5c 100644 --- a/bpmn/pom.xml +++ b/bpmn/pom.xml @@ -15,7 +15,7 @@ pom - 7.9.0 + 7.10.0 1.2 camunda-webapp-jboss-standalone 1.4.196 @@ -28,7 +28,7 @@ MSOCoreBPMN - + MSOCommonBPMN so-bpmn-infrastructure-common so-bpmn-tasks diff --git a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/AbstractBuilderTest.java b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/AbstractBuilderTest.java index 828e3fca47..4ac131f873 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/AbstractBuilderTest.java +++ b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/AbstractBuilderTest.java @@ -27,6 +27,7 @@ import java.util.List; import java.util.Map; import java.util.Set; +import org.camunda.bpm.engine.ProcessEngine; import org.camunda.bpm.engine.ProcessEngineServices; import org.camunda.bpm.engine.delegate.DelegateExecution; import org.camunda.bpm.engine.runtime.Incident; @@ -53,7 +54,7 @@ public class AbstractBuilderTest { private String operType; private String resourceType; private String requestId; - + @Override public String getProcessInstanceId() { return null; @@ -326,18 +327,30 @@ public class AbstractBuilderTest { public void removeVariablesLocal() { } + + @Override + public ProcessEngine getProcessEngine(){ + // TODO Auto-generated method stub + return null; + } + + @Override + public void setProcessBusinessKey(String arg0){ + // TODO Auto-generated method stub + + } }; @Test public void requestActionGetIntValueTest() { assertEquals(0, RequestAction.CREATE_NETWORK_INSTANCE.getIntValue()); } - + @Test public void svcActionGetIntValueTest() { assertEquals(0, SvcAction.RESERVE.getIntValue()); } - + @Test public void buildTest() throws Exception { abstractBuilder.build(null, null); @@ -347,75 +360,75 @@ public class AbstractBuilderTest { public void getRequestActionBlankOperationTypeTest() throws Exception { assertEquals(AbstractBuilder.RequestAction.CREATE_NETWORK_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionDeleteOperationTypeBlankResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, ""); assertEquals(AbstractBuilder.RequestAction.DELETE_SERVICE_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionDeleteOperationTypeBadResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "bad"); assertEquals(AbstractBuilder.RequestAction.DELETE_SERVICE_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionDeleteOperationTypeOverlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "overlay"); assertEquals(AbstractBuilder.RequestAction.DEACTIVATE_DCI_NETWORK_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionDeleteOperationTypeUnderlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "underlay"); assertEquals(AbstractBuilder.RequestAction.DELETE_NETWORK_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionDeleteOperationTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); assertEquals(AbstractBuilder.RequestAction.DELETE_SERVICE_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionCreateOperationTypeBlankResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, ""); assertEquals(AbstractBuilder.RequestAction.CREATE_SERVICE_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionCreateOperationTypeBadResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "bad"); assertEquals(AbstractBuilder.RequestAction.CREATE_SERVICE_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionCreateOperationTypeOverlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "overlay"); assertEquals(AbstractBuilder.RequestAction.ACTIVATE_DCI_NETWORK_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionCreateOperationTypeUnderlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "underlay"); assertEquals(AbstractBuilder.RequestAction.CREATE_NETWORK_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionCreateOperationTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); assertEquals(AbstractBuilder.RequestAction.CREATE_SERVICE_INSTANCE.getName(), abstractBuilder.getRequestAction(delegateExecution)); } - + @Test public void getRequestActionBadOperationType() { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, "bad"); @@ -426,75 +439,75 @@ public class AbstractBuilderTest { public void getSvcActionBlankOperationTypeTest() throws Exception { assertEquals(AbstractBuilder.SvcAction.CREATE.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionDeleteOperationTypeBlankResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, ""); assertEquals(AbstractBuilder.SvcAction.UNASSIGN.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionDeleteOperationTypeBadResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "bad"); assertEquals(AbstractBuilder.SvcAction.UNASSIGN.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionDeleteOperationTypeOverlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "overlay"); assertEquals(AbstractBuilder.SvcAction.DEACTIVATE.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionDeleteOperationTypeUnderlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "underlay"); assertEquals(AbstractBuilder.SvcAction.DELETE.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionDeleteOperationTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.DELETE); assertEquals(AbstractBuilder.SvcAction.UNASSIGN.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionCreateOperationTypeBlankResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, ""); assertEquals(AbstractBuilder.SvcAction.ASSIGN.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionCreateOperationTypeBadResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "bad"); assertEquals(AbstractBuilder.SvcAction.ASSIGN.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionCreateOperationTypeOverlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "overlay"); assertEquals(AbstractBuilder.SvcAction.ACTIVATE.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionCreateOperationTypeUnderlayResourceTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); delegateExecution.setVariable(AbstractBuilder.RESOURCE_TYPE, "underlay"); assertEquals(AbstractBuilder.SvcAction.CREATE.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionCreateOperationTypeTest() throws Exception { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, RequestsDbConstant.OperationType.CREATE); assertEquals(AbstractBuilder.SvcAction.ASSIGN.getName(), abstractBuilder.getSvcAction(delegateExecution)); } - + @Test public void getSvcActionBadOperationType() { delegateExecution.setVariable(AbstractBuilder.OPERATION_TYPE, "bad"); @@ -505,14 +518,14 @@ public class AbstractBuilderTest { public void getRequestIdBlankNotOnExecutionTest() { abstractBuilder.getRequestId(delegateExecution); } - + @Test public void getRequestIdBlankOnExecutionTest() { String expected = "requestId"; delegateExecution.setVariable("msoRequestId", expected); assertEquals(expected, abstractBuilder.getRequestId(delegateExecution)); } - + @Test public void getRequestIdTest() { String expected = "requestId"; @@ -539,13 +552,13 @@ public class AbstractBuilderTest { assertEquals("foo", list.get(0).getName()); assertEquals("bar", list.get(0).getValue()); } - + @Test public void getParamEntitiesNullInputsTest() { List list = abstractBuilder.getParamEntities(null); assertEquals(0, list.size()); } - + @Test public void getParamEntitiesEmptyInputsTest() { List list = abstractBuilder.getParamEntities(new HashMap<>()); diff --git a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/NetworkRpcInputEntityBuilderTest.java b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/NetworkRpcInputEntityBuilderTest.java index f7d73a33e1..4e39c7b4e3 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/NetworkRpcInputEntityBuilderTest.java +++ b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/NetworkRpcInputEntityBuilderTest.java @@ -7,9 +7,9 @@ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -24,6 +24,7 @@ import java.util.Collection; import java.util.Map; import java.util.Set; +import org.camunda.bpm.engine.ProcessEngine; import org.camunda.bpm.engine.ProcessEngineServices; import org.camunda.bpm.engine.delegate.DelegateExecution; import org.camunda.bpm.engine.runtime.Incident; @@ -35,12 +36,12 @@ import org.junit.Test; public class NetworkRpcInputEntityBuilderTest { NetworkRpcInputEntityBuilder networRpcInputEntityBuilder = new NetworkRpcInputEntityBuilder(); - + DelegateExecution delegateExecution = new DelegateExecution() { private String operType; private String resourceType; private String requestId; - + @Override public String getProcessInstanceId() { return null; @@ -313,6 +314,18 @@ public class NetworkRpcInputEntityBuilderTest { public void removeVariablesLocal() { } + + @Override + public ProcessEngine getProcessEngine(){ + // TODO Auto-generated method stub + return null; + } + + @Override + public void setProcessBusinessKey(String arg0){ + // TODO Auto-generated method stub + + } }; @Test diff --git a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/ServiceRpcInputEntityBuilderTest.java b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/ServiceRpcInputEntityBuilderTest.java index 4db0421936..556ff67fad 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/ServiceRpcInputEntityBuilderTest.java +++ b/bpmn/so-bpmn-infrastructure-common/src/test/java/org/onap/so/bpmn/infrastructure/workflow/serviceTask/client/builder/ServiceRpcInputEntityBuilderTest.java @@ -7,9 +7,9 @@ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -24,6 +24,7 @@ import java.util.Collection; import java.util.Map; import java.util.Set; +import org.camunda.bpm.engine.ProcessEngine; import org.camunda.bpm.engine.ProcessEngineServices; import org.camunda.bpm.engine.delegate.DelegateExecution; import org.camunda.bpm.engine.runtime.Incident; @@ -35,12 +36,12 @@ import org.junit.Test; public class ServiceRpcInputEntityBuilderTest { ServiceRpcInputEntityBuilder serviceRpcInputEntityBuilder = new ServiceRpcInputEntityBuilder(); - + DelegateExecution delegateExecution = new DelegateExecution() { private String operType; private String resourceType; private String requestId; - + @Override public String getProcessInstanceId() { return null; @@ -313,6 +314,18 @@ public class ServiceRpcInputEntityBuilderTest { public void removeVariablesLocal() { } + + @Override + public ProcessEngine getProcessEngine(){ + // TODO Auto-generated method stub + return null; + } + + @Override + public void setProcessBusinessKey(String arg0){ + // TODO Auto-generated method stub + + } }; @Test diff --git a/bpmn/so-bpmn-tasks/src/test/resources/schema.sql b/bpmn/so-bpmn-tasks/src/test/resources/schema.sql index 7a15e84662..5ae6a2d972 100644 --- a/bpmn/so-bpmn-tasks/src/test/resources/schema.sql +++ b/bpmn/so-bpmn-tasks/src/test/resources/schema.sql @@ -1184,5 +1184,12 @@ alter table ACT_ID_TENANT_MEMBER add constraint ACT_FK_TENANT_MEMB_GROUP foreign key (GROUP_ID_) references ACT_ID_GROUP (ID_); - - + +ALTER TABLE ACT_GE_BYTEARRAY + ADD TYPE_ integer; + +ALTER TABLE ACT_GE_BYTEARRAY + ADD CREATE_TIME_ datetime(3); + +ALTER TABLE ACT_RE_PROCDEF + ADD STARTABLE_ BOOLEAN NOT NULL DEFAULT TRUE; \ No newline at end of file diff --git a/mso-api-handlers/mso-api-handler-infra/pom.xml b/mso-api-handlers/mso-api-handler-infra/pom.xml index dd77c242d4..f3163840ec 100644 --- a/mso-api-handlers/mso-api-handler-infra/pom.xml +++ b/mso-api-handlers/mso-api-handler-infra/pom.xml @@ -14,7 +14,7 @@ mso-api-handler-infra ONAP SO API Handler Infra - 7.9.0 + 7.10.0 1.2 UTF-8 UTF-8 @@ -51,7 +51,7 @@ org.camunda.bpm camunda-engine - + org.springframework.boot spring-boot-starter-web diff --git a/pom.xml b/pom.xml index d7664ef342..1d5d53d9a7 100644 --- a/pom.xml +++ b/pom.xml @@ -65,8 +65,8 @@ content/sites/site/org/onap/so/${project.version}/ 3.2.6 2.1 - 2.0.5.RELEASE - 3.0.0 + 2.0.5.RELEASE + 3.2.0 @@ -397,13 +397,13 @@ ${docker.skip} ${docker.skip.build} ${docker.skip.push} - ${docker.newHost} - ${docker.host.cert.path} - ${dockerPushRepo} - ${dockerPullRepo} @@ -522,27 +522,27 @@ com.fasterxml.jackson.core - jackson-core + jackson-core com.fasterxml.jackson.module - jackson-module-jaxb-annotations + jackson-module-jaxb-annotations com.fasterxml.jackson.core - jackson-databind + jackson-databind com.fasterxml.jackson.core - jackson-annotations + jackson-annotations com.fasterxml.jackson.jaxrs - jackson-jaxrs-base + jackson-jaxrs-base com.fasterxml.jackson.jaxrs - jackson-jaxrs-json-provider + jackson-jaxrs-json-provider javax.ws.rs @@ -573,7 +573,7 @@ junit - junit + junit test @@ -666,7 +666,7 @@ - org.apache.httpcomponents @@ -685,7 +685,7 @@ commons-io 2.5 compile - + com.sun.xml.fastinfoset FastInfoset -- 2.16.6