From 833d219c3b6689ea27f46719a3a00cbaf7e649fe Mon Sep 17 00:00:00 2001 From: "Kuleshov, Elena" Date: Fri, 10 Jan 2020 09:53:29 -0500 Subject: 1911 create appc adapter micro service Added new appc adapter micro service. Made required code changes to use the new adapter. Issue-ID: SO-2596 Signed-off-by: Benjamin, Max (mb388a) Change-Id: I880ecace64ec85ca4094a82bc1210798fd3bb85d --- common/pom.xml | 61 ++++++++++++ .../beans/ApplicationControllerTaskRequest.java | 104 +++++++++++++++++++++ .../service/beans/ApplicationControllerVm.java | 30 ++++++ .../service/beans/ApplicationControllerVnf.java | 49 ++++++++++ common/src/test/java/org/onap/so/BeansTest.java | 1 + 5 files changed, 245 insertions(+) create mode 100644 common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerTaskRequest.java create mode 100644 common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVm.java create mode 100644 common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVnf.java (limited to 'common') diff --git a/common/pom.xml b/common/pom.xml index 94b28e91bd..cdd5df950a 100644 --- a/common/pom.xml +++ b/common/pom.xml @@ -16,6 +16,7 @@ 3.6.1 4.1.30.Final 0.4.2 + 1.6.0-SNAPSHOT @@ -202,6 +203,66 @@ camunda-external-task-client 1.1.1 + + org.onap.appc.client + client-lib + ${appc.client.version} + + + org.mockito + mockito-core + + + org.powermock + powermock-module-junit4 + + + org.powermock + powermock-api-mockito + + + + + org.onap.appc.client + client-kit + ${appc.client.version} + + + org.mockito + mockito-core + + + + + org.onap.appc.client + client-lib + ${appc.client.version} + + + org.mockito + mockito-core + + + org.powermock + powermock-module-junit4 + + + org.powermock + powermock-api-mockito + + + + + org.onap.appc.client + client-kit + ${appc.client.version} + + + org.mockito + mockito-core + + + diff --git a/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerTaskRequest.java b/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerTaskRequest.java new file mode 100644 index 0000000000..3811b52551 --- /dev/null +++ b/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerTaskRequest.java @@ -0,0 +1,104 @@ +package org.onap.so.appc.orchestrator.service.beans; + +import java.io.Serializable; +import org.onap.appc.client.lcm.model.Action; +import org.onap.so.appc.orchestrator.service.beans.ApplicationControllerVnf; + +public class ApplicationControllerTaskRequest implements Serializable { + + private static final long serialVersionUID = -3150320542857627682L; + + private Action action; + private String controllerType; + private String identityUrl; + private String operationsTimeout; + private String bookName; + private String nodeList; + private String fileParameters; + private String existingSoftwareVersion; + private String newSoftwareVersion; + private ApplicationControllerVnf applicationControllerVnf; + + public Action getAction() { + return action; + } + + public void setAction(Action action) { + this.action = action; + } + + public String getControllerType() { + return controllerType; + } + + public void setControllerType(String controllerType) { + this.controllerType = controllerType; + } + + public ApplicationControllerVnf getApplicationControllerVnf() { + return applicationControllerVnf; + } + + public void setApplicationControllerVnf(ApplicationControllerVnf applicationControllerVnf) { + this.applicationControllerVnf = applicationControllerVnf; + } + + public String getIdentityUrl() { + return identityUrl; + } + + public void setIdentityUrl(String identityUrl) { + this.identityUrl = identityUrl; + } + + public String getOperationsTimeout() { + return operationsTimeout; + } + + public void setOperationsTimeout(String operationsTimeout) { + this.operationsTimeout = operationsTimeout; + } + + public String getBookName() { + return bookName; + } + + public void setBookName(String bookName) { + this.bookName = bookName; + } + + public String getNodeList() { + return nodeList; + } + + public void setNodeList(String nodeList) { + this.nodeList = nodeList; + } + + public String getFileParameters() { + return fileParameters; + } + + public void setFileParameters(String fileParameters) { + this.fileParameters = fileParameters; + } + + public String getExistingSoftwareVersion() { + return existingSoftwareVersion; + } + + public void setExistingSoftwareVersion(String existingSoftwareVersion) { + this.existingSoftwareVersion = existingSoftwareVersion; + } + + public String getNewSoftwareVersion() { + return newSoftwareVersion; + } + + public void setNewSoftwareVersion(String newSoftwareVersion) { + this.newSoftwareVersion = newSoftwareVersion; + } + + + +} diff --git a/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVm.java b/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVm.java new file mode 100644 index 0000000000..75e2053077 --- /dev/null +++ b/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVm.java @@ -0,0 +1,30 @@ +package org.onap.so.appc.orchestrator.service.beans; + +import java.io.Serializable; +import java.util.List; + +public class ApplicationControllerVm implements Serializable { + + private static final long serialVersionUID = 2786675508024214638L; + + private String vserverId; + private String vmId; + + public String getVserverId() { + return vserverId; + } + + public void setVserverId(String vserverId) { + this.vserverId = vserverId; + } + + public String getVmId() { + return vmId; + } + + public void setVmId(String vmId) { + this.vmId = vmId; + } + + +} diff --git a/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVnf.java b/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVnf.java new file mode 100644 index 0000000000..526941dc39 --- /dev/null +++ b/common/src/main/java/org/onap/so/appc/orchestrator/service/beans/ApplicationControllerVnf.java @@ -0,0 +1,49 @@ +package org.onap.so.appc.orchestrator.service.beans; + +import java.io.Serializable; +import java.util.List; + +public class ApplicationControllerVnf implements Serializable { + + private static final long serialVersionUID = 2786675508024214637L; + + private String vnfId; + private String vnfName; + private String vnfHostIpAddress; + private ApplicationControllerVm applicationControllerVm; + + public String getVnfId() { + return vnfId; + } + + public void setVnfId(String vnfId) { + this.vnfId = vnfId; + } + + public String getVnfName() { + return vnfName; + } + + public void setVnfName(String vnfName) { + this.vnfName = vnfName; + } + + public String getVnfHostIpAddress() { + return vnfHostIpAddress; + } + + public void setVnfHostIpAddress(String vnfHostIpAddress) { + this.vnfHostIpAddress = vnfHostIpAddress; + } + + public ApplicationControllerVm getApplicationControllerVm() { + return applicationControllerVm; + } + + public void setApplicationControllerVm(ApplicationControllerVm applicationControllerVm) { + this.applicationControllerVm = applicationControllerVm; + } + + + +} diff --git a/common/src/test/java/org/onap/so/BeansTest.java b/common/src/test/java/org/onap/so/BeansTest.java index 8bde3c4eb7..9e8a0184ab 100644 --- a/common/src/test/java/org/onap/so/BeansTest.java +++ b/common/src/test/java/org/onap/so/BeansTest.java @@ -60,6 +60,7 @@ public class BeansTest { @Test public void pojoStructure() { + test("org.onap.so.appc.orchestrator.service.beans"); test("org.onap.so.client.policy.entities"); test("org.onap.so.client.grm.beans"); test("org.onap.so.client.ruby.beans"); -- cgit 1.2.3-korg