summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--appc-dg/appc-dg-shared/appc-dg-domain-model-lib/src/main/java/org/onap/appc/domainmodel/Vnf.java7
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/pom.xml14
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/SequenceGenerator.java2
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dbservices/SequenceGeneratorDBServices.java77
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dgplugin/impl/SequenceGeneratorPluginImpl.java7
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/PayloadGenerator.java123
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/RestartSequenceGenerator.java14
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StartSequenceGenerator.java11
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StopSequenceGenerator.java11
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/provider/SequenceGeneratorProvider.java3
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/main/resources/payload.json27
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/java/org/onap/appc/seqgen/TestSequenceGeneratorPlugin.java28
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json240
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckVNfcInInventory.json234
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json14
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json8
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json8
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json16
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json14
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json14
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json9
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-single-vm.json52
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json71
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json88
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json206
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start.json267
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json10
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm-per-vnfc.json60
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm.json51
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json6
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json7
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop.json10
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json276
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongnumber.json276
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json2
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-Nodep-SingleVM.json4
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVM-.json4
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json4
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json2
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json4
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json4
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json4
-rw-r--r--appc-sequence-generator/appc-sequence-generator-model/src/main/yang/sequence-generator.yang6
43 files changed, 1304 insertions, 991 deletions
diff --git a/appc-dg/appc-dg-shared/appc-dg-domain-model-lib/src/main/java/org/onap/appc/domainmodel/Vnf.java b/appc-dg/appc-dg-shared/appc-dg-domain-model-lib/src/main/java/org/onap/appc/domainmodel/Vnf.java
index b23142203..97fbfdb31 100644
--- a/appc-dg/appc-dg-shared/appc-dg-domain-model-lib/src/main/java/org/onap/appc/domainmodel/Vnf.java
+++ b/appc-dg/appc-dg-shared/appc-dg-domain-model-lib/src/main/java/org/onap/appc/domainmodel/Vnf.java
@@ -33,6 +33,7 @@ public class Vnf {
private String vnfId;
private String vnfType;
private String vnfVersion;
+ private String identityUrl;
private List <Vserver> vservers;
public Vnf(){
@@ -93,5 +94,11 @@ public class Vnf {
return new LinkedList<>(vnfcs);
}
+ public String getIdentityUrl() {
+ return identityUrl;
+ }
+ public void setIdentityUrl(String identityUrl) {
+ this.identityUrl = identityUrl;
+ }
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/pom.xml b/appc-sequence-generator/appc-sequence-generator-bundle/pom.xml
index 9e7328544..9e7f43889 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/pom.xml
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/pom.xml
@@ -199,6 +199,20 @@
<artifactId>domain-model-lib</artifactId>
<version>${project.version}</version>
</dependency>
+ <dependency>
+ <groupId>org.apache.velocity</groupId>
+ <artifactId>velocity</artifactId>
+ <version>1.7</version>
+ </dependency>
+ <dependency>
+ <groupId>org.onap.ccsdk.sli.adaptors</groupId>
+ <artifactId>sql-resource-provider</artifactId>
+ <version>${ccsdk.sli.adaptors.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ </dependency>
<dependency>
<groupId>org.onap.appc</groupId>
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/SequenceGenerator.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/SequenceGenerator.java
index 974a8ea63..9006e85eb 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/SequenceGenerator.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/SequenceGenerator.java
@@ -40,5 +40,5 @@ public interface SequenceGenerator {
* @return returns runtime sequence for LCM operation execution
* @throws APPCException
*/
- List<Transaction> generateSequence(SequenceGeneratorInput input) throws APPCException;
+ List<Transaction> generateSequence(SequenceGeneratorInput input) throws Exception;
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dbservices/SequenceGeneratorDBServices.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dbservices/SequenceGeneratorDBServices.java
new file mode 100644
index 000000000..8411c2b81
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dbservices/SequenceGeneratorDBServices.java
@@ -0,0 +1,77 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2018 AT&T Intellectual Property. All rights reserved.
+ * =============================================================================
+ * 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.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.appc.seqgen.dbservices;
+
+import org.onap.ccsdk.sli.core.sli.SvcLogicContext;
+import org.onap.ccsdk.sli.core.sli.SvcLogicException;
+import org.onap.ccsdk.sli.core.sli.SvcLogicResource;
+import org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource;
+import org.onap.ccsdk.sli.core.sli.SvcLogicResource.QueryStatus;
+import org.onap.ccsdk.sli.core.dblib.DBResourceManager;
+
+import com.att.eelf.configuration.EELFLogger;
+import com.att.eelf.configuration.EELFManager;
+
+public class SequenceGeneratorDBServices {
+
+ private static final EELFLogger log = EELFManager.getInstance().getLogger(SequenceGeneratorDBServices.class);
+ private static SequenceGeneratorDBServices dgGeneralDBService = null;
+ private final SvcLogicResource serviceLogic;
+
+ public static SequenceGeneratorDBServices initialise() {
+ if (dgGeneralDBService == null) {
+ dgGeneralDBService = new SequenceGeneratorDBServices();
+ }
+ return dgGeneralDBService;
+ }
+
+ public SequenceGeneratorDBServices() {
+ serviceLogic = new SqlResource();
+ }
+
+ public String getOutputPayloadTemplate(SvcLogicContext localContext) throws SvcLogicException {
+ String fn = "DBService.getPayloadOutput";
+ log.info("Entering getOutputPayloadTemplate()");
+ QueryStatus status = null;
+ if (localContext == null) return null;
+ localContext.setAttribute("file_category", "output_payload");
+ String queryString = "select max(internal_version) as maxInternalVersion, artifact_name as artifactName from "
+ + "asdc_artifacts" + " where artifact_name in (select artifact_name from " + "asdc_artifacts"
+ + " where file_category = '" + "payload" + "' )";
+
+ log.info(fn + "Query String : " + queryString);
+ status = serviceLogic.query("SQL", false, null, queryString, null, null, localContext);
+
+ if (status == QueryStatus.FAILURE)
+ throw new SvcLogicException("Error - while getting output payload template");
+
+ String queryString1 = "select artifact_content from " + "asdc_artifacts"
+ + " where artifact_name = $artifactName and internal_version = $maxInternalVersion ";
+
+ log.debug(fn + "Query String : " + queryString1);
+ status = serviceLogic.query("SQL", false, null, queryString1, null, null, localContext);
+ if (status == QueryStatus.FAILURE)
+ throw new SvcLogicException("Error - while getting output payload template");
+ log.debug("Template for the payload data:" + localContext.getAttribute("artifact-content"));
+ return localContext != null ? localContext.getAttribute("artifact-content") : null;
+ }
+}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dgplugin/impl/SequenceGeneratorPluginImpl.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dgplugin/impl/SequenceGeneratorPluginImpl.java
index b804574e9..a53c408e8 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dgplugin/impl/SequenceGeneratorPluginImpl.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/dgplugin/impl/SequenceGeneratorPluginImpl.java
@@ -96,7 +96,7 @@ public class SequenceGeneratorPluginImpl implements SequenceGeneratorPlugin {
return sequenceGeneratorInput;
}
- private List<Transaction> generateSequence(SequenceGeneratorInput sequenceGeneratorInput) throws APPCException {
+ private List<Transaction> generateSequence(SequenceGeneratorInput sequenceGeneratorInput) throws Exception {
if (sequenceGeneratorInput.getRequestInfo() == null) {
throw new APPCException("Request info is not provided in the input");
}
@@ -262,9 +262,12 @@ public class SequenceGeneratorPluginImpl implements SequenceGeneratorPlugin {
String vnfId = vnfInfo.get("vnf-id").asText();
String vnfType = vnfInfo.get("vnf-type").asText();
+ String identityUrl = vnfInfo.get("identity-url").asText();
Vnf vnf =new Vnf();
vnf.setVnfId(vnfId);
vnf.setVnfType(vnfType);
+ vnf.setIdentityUrl(identityUrl);
+ logger.debug("IdentityUrl in SeqGen:" + identityUrl);
Map<Vnfc, List<Vserver>> vfcs = new HashMap<>();
JsonNode vms = vnfInfo.get("vm");
if(vms.size()<1){
@@ -275,8 +278,10 @@ public class SequenceGeneratorPluginImpl implements SequenceGeneratorPlugin {
throw new APPCException("vserver-id not found ");
}
String vserverId = vm.get("vserver-id").asText();
+ String vmId =vm.get("vm-id").asText();
Vserver vserver = new Vserver();
vserver.setId(vserverId);
+ vserver.setUrl(vmId);
if (vm.get("vnfc")!=null&& vm.get("vnfc").get("vnfc-name") != null && vm.get("vnfc").get("vnfc-type")!= null) {
Vnfc vfc = new Vnfc();
vfc.setVnfcType(vm.get("vnfc").get("vnfc-type").asText());
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/PayloadGenerator.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/PayloadGenerator.java
new file mode 100644
index 000000000..a7eb8593c
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/PayloadGenerator.java
@@ -0,0 +1,123 @@
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP : APPC
+ * ================================================================================
+ * Copyright (C) 2018 AT&T Intellectual Property. All rights reserved.
+ * =============================================================================
+ * 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.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.appc.seqgen.impl;
+
+import java.io.InputStream;
+import java.io.StringReader;
+import java.io.StringWriter;
+import org.onap.appc.seqgen.dbservices.SequenceGeneratorDBServices;
+import org.onap.appc.seqgen.objects.SequenceGeneratorInput;
+import com.fasterxml.jackson.databind.DeserializationFeature;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.att.eelf.configuration.EELFLogger;
+import com.att.eelf.configuration.EELFManager;
+
+import org.apache.velocity.*;
+import org.apache.velocity.runtime.RuntimeServices;
+import org.apache.velocity.runtime.RuntimeSingleton;
+import org.apache.velocity.runtime.parser.ParseException;
+import org.apache.velocity.runtime.parser.node.SimpleNode;
+import org.onap.ccsdk.sli.core.sli.SvcLogicContext;
+import org.apache.commons.io.IOUtils;
+
+
+public class PayloadGenerator {
+
+ private static final EELFLogger logger = EELFManager.getInstance().getLogger(PayloadGenerator.class);
+ private SequenceGeneratorDBServices dbService;
+
+ public String getPayload(SequenceGeneratorInput input, String vmId, String url)throws Exception {
+ SequenceGeneratorDBServices services = new SequenceGeneratorDBServices();
+ SvcLogicContext ctx = new SvcLogicContext();
+ String payload = null;
+ String payloadTemplate = null;
+ InputStream data = getClass().getClassLoader().getResourceAsStream("payload.json");
+ String payloadTemplatefromRes = IOUtils.toString(data);
+ System.out.println("Input template data: " + payloadTemplatefromRes);
+ logger.debug("Input template data: " + payloadTemplatefromRes);
+ payloadTemplate=payloadTemplatefromRes;
+
+ if (payloadTemplate != null) {
+ ObjectMapper mapper = new ObjectMapper();
+ mapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
+ mapper.enable(DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY);
+
+ JsonNode payloadModel = mapper.readTree(payloadTemplate).get("output_payload-model");
+ logger.debug("Payload template:"+payloadModel.toString());
+
+ JsonNode modelName = payloadModel.get("sequence-generator");
+ logger.debug("Payload Model Name:" + modelName);
+
+ JsonNode action = payloadModel.path("action-list");
+ if (action.isArray()) {
+ for (JsonNode nodes : action) {
+ String actionName = nodes.path("action").asText();
+ JsonNode payloadValues = nodes.path("payload-fields");
+ logger.debug("Action Name: " + actionName + "-" + "Payload values: " + payloadValues);
+ String actionValue = input.getRequestInfo().getAction();
+ if (actionName.equalsIgnoreCase(actionValue)) {
+ JsonNode template = nodes.path("payload-fields");
+ logger.debug("Payload template:" + template);
+ payload = generatePayloadFromTemplate(template.toString(),input,url);
+ break;
+
+ }
+
+ }
+ }
+
+ }
+
+ return payload;
+ }
+
+ public String generatePayloadFromTemplate(String template,SequenceGeneratorInput input,String vmId) throws ParseException {
+
+ String payload = null;
+
+ RuntimeServices runtimeServices = RuntimeSingleton.getRuntimeServices();
+ StringReader reader = new StringReader(template);
+ SimpleNode node = runtimeServices.parse(reader,template);
+
+ Template templateData = new Template();
+ templateData.setRuntimeServices(runtimeServices);
+ templateData.setData(node);
+ templateData.initDocument();
+
+ VelocityContext vc = new VelocityContext();
+ String identityUrl = input.getInventoryModel().getVnf().getIdentityUrl();
+ logger.debug("IdentityUrl:" + identityUrl);
+ logger.debug("Vm-Id:" + vmId);
+ vc.put("identity-url", identityUrl);
+ vc.put("vm-id", vmId);
+
+ StringWriter stringWriter = new StringWriter();
+ templateData.merge(vc, stringWriter);
+
+ payload= stringWriter.toString();
+ logger.debug("Payload Data:" +stringWriter.toString());
+
+ return payload;
+
+ }
+}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/RestartSequenceGenerator.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/RestartSequenceGenerator.java
index 83ed9627d..85d5bc923 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/RestartSequenceGenerator.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/RestartSequenceGenerator.java
@@ -43,16 +43,18 @@ public class RestartSequenceGenerator implements SequenceGenerator{
private static final EELFLogger logger = EELFManager.getInstance().getLogger(RestartSequenceGenerator.class);
@Override
- public List<Transaction> generateSequence(SequenceGeneratorInput input) throws APPCException {
+ public List<Transaction> generateSequence(SequenceGeneratorInput input) throws Exception {
logger.info("Generating sequence without dependency model");
return generateSequenceWithOutDependency(input);
}
- private List<Transaction> generateSequenceWithOutDependency(SequenceGeneratorInput input) {
+ private List<Transaction> generateSequenceWithOutDependency(SequenceGeneratorInput input) throws Exception{
+ String payload = null;
List<Transaction> transactionList = new LinkedList<>();
Integer transactionId = 1;
List<Vserver> vservers = input.getInventoryModel().getVnf().getVservers();
List<Integer> transactionIds = new LinkedList<>();
+ PayloadGenerator payloadGenerator = new PayloadGenerator();
for (Vserver vm : vservers) {
Transaction transactionStop = new Transaction();
transactionStop.setTransactionId(transactionId);
@@ -62,7 +64,10 @@ public class RestartSequenceGenerator implements SequenceGenerator{
ActionIdentifier actionIdentifier = new ActionIdentifier();
actionIdentifier.setvServerId(vm.getId());
transactionStop.setActionIdentifier(actionIdentifier);
- transactionStop.setPayload(input.getRequestInfo().getPayload());
+ String vmId = vm.getId();
+ String url = vm.getUrl();
+ payload = payloadGenerator.getPayload(input, vmId, url);
+ transactionStop.setPayload(payload);
if (vservers.size()>1) {
Response failureResponse = new Response();
failureResponse.setResponseMessage(Constants.ResponseMessage.FAILURE.getResponse());
@@ -83,7 +88,8 @@ public class RestartSequenceGenerator implements SequenceGenerator{
ActionIdentifier actionIdentifierStart = new ActionIdentifier();
actionIdentifierStart.setvServerId(vm.getId());
transactionStart.setActionIdentifier(actionIdentifierStart);
- transactionStart.setPayload(input.getRequestInfo().getPayload());
+ payload = payloadGenerator.getPayload(input, vmId, url);
+ transactionStart.setPayload(payload);
if (vservers.size()>1) {
Response failureResponse = new Response();
failureResponse.setResponseMessage(Constants.ResponseMessage.FAILURE.getResponse());
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StartSequenceGenerator.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StartSequenceGenerator.java
index 02e5f7fbd..8c24fe24c 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StartSequenceGenerator.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StartSequenceGenerator.java
@@ -67,8 +67,10 @@ public class StartSequenceGenerator implements SequenceGenerator {
private static final EELFLogger logger = EELFManager.getInstance().getLogger(StartSequenceGenerator.class);
- private List<Transaction> generateSequenceWithOutDependency(SequenceGeneratorInput input) throws APPCException {
+ private List<Transaction> generateSequenceWithOutDependency(SequenceGeneratorInput input) throws Exception {
+ String payload = null;
+ PayloadGenerator payloadGenerator = new PayloadGenerator();
List<Transaction> transactionList = new LinkedList<>();
Integer transactionId = 1;
List<Vserver> vservers = input.getInventoryModel().getVnf().getVservers();
@@ -82,7 +84,10 @@ public class StartSequenceGenerator implements SequenceGenerator {
ActionIdentifier actionIdentifier = new ActionIdentifier();
actionIdentifier.setvServerId(vm.getId());
transaction.setActionIdentifier(actionIdentifier);
- transaction.setPayload(input.getRequestInfo().getPayload());
+ String vmId = vm.getUrl();
+ String url = vm.getUrl();
+ payload = payloadGenerator.getPayload(input, vmId, url);
+ transaction.setPayload(payload);
if(vservers.size()>1){
Response ignoreResponse = new Response();
ignoreResponse.setResponseMessage(ResponseMessage.FAILURE.getResponse());
@@ -213,7 +218,7 @@ public class StartSequenceGenerator implements SequenceGenerator {
}
@Override
- public List<Transaction> generateSequence(SequenceGeneratorInput input) throws APPCException {
+ public List<Transaction> generateSequence(SequenceGeneratorInput input) throws Exception {
if (input.getRequestInfo().getActionLevel().equals(ActionLevel.VNF.getAction()) && input.getDependencyModel() != null) {
if(isVnfcPresent(input)) {
FlowStrategies flowStrategy = readFlowStrategy(input);
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StopSequenceGenerator.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StopSequenceGenerator.java
index ec1105d88..63ec1731e 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StopSequenceGenerator.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/impl/StopSequenceGenerator.java
@@ -60,7 +60,7 @@ public class StopSequenceGenerator implements SequenceGenerator {
private static final EELFLogger logger = EELFManager.getInstance().getLogger(StopSequenceGenerator.class);
@Override
- public List<Transaction> generateSequence(SequenceGeneratorInput input) throws APPCException {
+ public List<Transaction> generateSequence(SequenceGeneratorInput input) throws Exception {
if (input.getRequestInfo().getActionLevel().equals(ActionLevel.VNF.getAction()) && input.getDependencyModel() != null ) {
if(isVnfcPresent(input)) {
FlowStrategies flowStrategy = readFlowStrategy(input);
@@ -81,7 +81,9 @@ public class StopSequenceGenerator implements SequenceGenerator {
}
}
- private List<Transaction> generateSequenceWithOutDependency(SequenceGeneratorInput input){
+ private List<Transaction> generateSequenceWithOutDependency(SequenceGeneratorInput input)throws Exception{
+ String payload = null;
+ PayloadGenerator payloadGenerator = new PayloadGenerator();
List<Transaction> transactionList = new LinkedList<>();
Integer transactionId = 1;
List<Vserver> vservers = input.getInventoryModel().getVnf().getVservers();
@@ -95,7 +97,10 @@ public class StopSequenceGenerator implements SequenceGenerator {
ActionIdentifier actionIdentifier = new ActionIdentifier();
actionIdentifier.setvServerId(vm.getId());
transaction.setActionIdentifier(actionIdentifier);
- transaction.setPayload(input.getRequestInfo().getPayload());
+ String vmId = vm.getId();
+ String url = vm.getUrl();
+ payload = payloadGenerator.getPayload(input, vmId, url);
+ transaction.setPayload(payload);
if(vservers.size()>1){
Response failureResponse = new Response();
failureResponse.setResponseMessage(ResponseMessage.FAILURE.getResponse());
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/provider/SequenceGeneratorProvider.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/provider/SequenceGeneratorProvider.java
index 86691a3fe..f00a05455 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/provider/SequenceGeneratorProvider.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/java/org/onap/appc/seqgen/provider/SequenceGeneratorProvider.java
@@ -123,7 +123,7 @@ public class SequenceGeneratorProvider implements AutoCloseable,SequenceGenerato
SequenceGeneratorInput seqGenInput = buildSeqGenInput(input);
List<Transaction> transactions = seqGenerator.generateSequence(seqGenInput);
rpcResult = buildSuccessResponse(transactions);
- } catch (APPCException e) {
+ } catch (Exception e) {
log.error("Error Generating Sequence",e);
rpcResult = buildFailureResponse(e.getMessage());
}
@@ -471,6 +471,7 @@ public class SequenceGeneratorProvider implements AutoCloseable,SequenceGenerato
Vnf vnf=new Vnf();
vnf.setVnfId(input.getInventoryInfo().getVnfInfo().getVnfId());
vnf.setVnfType(input.getInventoryInfo().getVnfInfo().getVnfType());
+ vnf.setIdentityUrl(input.getInventoryInfo().getVnfInfo().getIdentityUrl());
return vnf;
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/main/resources/payload.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/resources/payload.json
new file mode 100644
index 000000000..58eb605e2
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/main/resources/payload.json
@@ -0,0 +1,27 @@
+{
+"output_payload-model": {
+ "sequence-generator": "multistep-sequence-generator",
+ "action-list": [{
+ "action": "start",
+ "payload-fields": {
+ "identity-url": "$identity-url",
+ "vm-id": "$vm-id"
+ }
+ },
+ {
+ "action": "stop",
+ "payload-fields": {
+ "identity-url": "$identity-url",
+ "vm-id": "$vm-id"
+ }
+ },
+ {
+ "action": "restart",
+ "payload-fields": {
+ "identity-url": "$identity-url",
+ "vm-id": "$vm-id"
+ }
+ }
+ ]
+ }
+}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/java/org/onap/appc/seqgen/TestSequenceGeneratorPlugin.java b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/java/org/onap/appc/seqgen/TestSequenceGeneratorPlugin.java
index 79741d552..addd81a4b 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/java/org/onap/appc/seqgen/TestSequenceGeneratorPlugin.java
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/java/org/onap/appc/seqgen/TestSequenceGeneratorPlugin.java
@@ -4,8 +4,6 @@
* ================================================================================
* Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved.
* ================================================================================
- * Copyright (C) 2017 Amdocs
- * =============================================================================
* 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
@@ -26,11 +24,13 @@ package org.onap.appc.seqgen;
import com.att.eelf.configuration.EELFLogger;
import com.att.eelf.configuration.EELFManager;
import org.junit.Assert;
+import org.junit.Before;
import org.junit.Test;
+import org.onap.appc.seqgen.dbservices.SequenceGeneratorDBServices;
import org.onap.appc.seqgen.dgplugin.SequenceGeneratorPlugin;
import org.onap.appc.seqgen.dgplugin.impl.SequenceGeneratorPluginImpl;
import org.onap.ccsdk.sli.core.sli.SvcLogicContext;
-
+import static org.mockito.Mockito.mock;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
@@ -41,6 +41,7 @@ import java.util.Map;
public class TestSequenceGeneratorPlugin {
private static final EELFLogger logger = EELFManager.getInstance().getLogger(TestSequenceGeneratorPlugin.class);
+ private SequenceGeneratorPlugin seqImpl;
@Test
public void testGenerateSequenceStart() throws URISyntaxException, IOException {
@@ -50,8 +51,8 @@ public class TestSequenceGeneratorPlugin {
SvcLogicContext context = new SvcLogicContext();
context.setAttribute("inputJSON",inputJSON);
- SequenceGeneratorPlugin plugin = new SequenceGeneratorPluginImpl();
- plugin.generateSequence(params,context);
+ seqImpl = new SequenceGeneratorPluginImpl();
+ seqImpl.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
String actualOutput = readOutput("/output/Start2.json");
@@ -280,23 +281,6 @@ public class TestSequenceGeneratorPlugin {
}
@Test
- public void testGenerateSequenceStopWithoutDep() throws URISyntaxException,IOException{
- String inputJSON = readInput("/input/stop-WithoutDep.json");
-
- Map<String,String> params = new HashMap<>();
- SvcLogicContext context = new SvcLogicContext();
- context.setAttribute("inputJSON",inputJSON);
-
- SequenceGeneratorPlugin plugin = new SequenceGeneratorPluginImpl();
- plugin.generateSequence(params,context);
-
- String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/stop-WithoutDep.json");
-
- Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
- }
-
- @Test
public void testGenerateSequenceVnfcNotPresentInInventory() throws URISyntaxException, IOException {
String inputJSON = readInput("/input/CheckVNfcInInventory.json");
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json
index 8af3e7332..0a4f5fce5 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json
@@ -1,124 +1,130 @@
{
- "request-info": {
- "action": "Start",
- "action-level": "vnf",
- "action-identifier": {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "fe_vserverid1",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
-
- },
- {
- "vserver-id" : "fe_vserverid2",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid2",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid3",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid4",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
+"request-info": {
+ "action": "Start",
+ "action-level": "vnf",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
},
- {
- "vserver-id" : "be_vserverid5",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
+ "payload": "ABC"
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id": "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version": "1.0",
+ "identity-url": "test-url",
+ "vm": [
+ {
+ "vserver-id": "be_vserverid1",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ },
+ {
+ "vserver-id": "fe_vserverid1",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+ },
+ {
+ "vserver-id": "fe_vserverid2",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+ },
+ {
+ "vserver-id": "be_vserverid2",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ },
+ {
+ "vserver-id": "be_vserverid3",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ },
+ {
+ "vserver-id": "be_vserverid4",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ },
+ {
+ "vserver-id": "be_vserverid5",
+ "vm-id": "vm-id",
+ "vnfc": {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ }
+ ]
}
- ]
- }
- },
- "dependency-info": {
- "vnfcs" : [
- {
- "vnfc-type" : "BE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "SMP"
- ]
- },
- {
- "vnfc-type" : "FE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "BE"
+ },
+ "dependency-info": {
+ "vnfcs": [
+ {
+ "vnfc-type": "BE",
+ "mandatory": "true",
+ "resilience": "Active-Active",
+ "parents": [
+ "SMP"
+ ]
+ },
+ {
+ "vnfc-type": "FE",
+ "mandatory": "true",
+ "resilience": "Active-Active",
+ "parents": [
+ "BE"
+ ]
+ },
+ {
+ "vnfc-type": "SMP",
+ "mandatory": "true",
+ "resilience": "Active-Passive",
+ "parents": []
+ }
]
- },
- {
- "vnfc-type" : "SMP",
- "mandatory" : "true",
- "resilience": "Active-Passive",
- "parents" : [
-
+ },
+ "tunable-parameters": {
+ "strategy": "FORWARD",
+ "wait-time": "120",
+ "retry-count": "5"
+ },
+ "capabilities": {
+ "vnf": [
+ "Stop",
+ "Start",
+ "StartApplication",
+ "StopApplication"
+ ],
+ "vf-module": [
+ "Stop",
+ "Start"
+ ],
+ "vm": [
+ "Stop",
+ "Start"
+ ],
+ "vnfc": [
+ "StopApplication",
+ "StartApplication",
+ "HealthCheck"
]
- }
-
- ]
- },
- "tunable-parameters": {
- "strategy" : "FORWARD",
- "wait-time": "120",
- "retry-count": "5"
- },
- "capabilities" : {
- "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
- "vf-module": ["Stop", "Start"],
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ }
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckVNfcInInventory.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckVNfcInInventory.json
index 2630ee749..8a4d22622 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckVNfcInInventory.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckVNfcInInventory.json
@@ -1,130 +1,136 @@
-
{
- "request-info":
+"request-info":
{
- "action": "Start",
- "action-level": "vnf",
- "action-identifier":
+ "action": "Start",
+ "action-level": "vnf",
+ "action-identifier":
{
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info":
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": "ABC"
+ },
+ "inventory-info":
{
- "vnf-info":
+ "vnf-info":
{
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "fe_vserverid1",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "fe_vserverid2",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid2",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid3",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid3",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid4",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid4",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid5",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info" :
- {
- "vnfcs" : [
- {
- "vnfc-type" : "BE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "SMP"
- ]
- },
- {
- "vnfc-type" : "FE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "BE"
- ]
- },
- {
- "vnfc-type" : "SMP",
- "mandatory" : "false",
- "resilience": "Active-Passive",
- "parents" : []
- }
- ]
- },
- "tunable-parameters" :
+ }
+ ]
+ }
+ },
+ "dependency-info" :
+ {
+ "vnfcs" : [
+ {
+ "vnfc-type" : "BE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "SMP"
+ ]
+ },
+ {
+ "vnfc-type" : "FE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "BE"
+ ]
+ },
+ {
+ "vnfc-type" : "SMP",
+ "mandatory" : "false",
+ "resilience": "Active-Passive",
+ "parents" : []
+ }
+ ]
+ },
+ "tunable-parameters" :
{
- "strategy" : "FORWARD",
- "wait-time" : "120",
- "retry-count" : "5"
- },
- "capabilities" :
+ "strategy" : "FORWARD",
+ "wait-time" : "120",
+ "retry-count" : "5"
+ },
+ "capabilities" :
{
- "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
- "vf-module": ["Stop", "Start"],
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
+ "vf-module": ["Stop", "Start"],
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json
index 667565d0a..372445f15 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json
@@ -1,5 +1,5 @@
{
- "request-info": {
+"request-info": {
"action": "Start",
"action-level": "vnf",
"action-identifier": {
@@ -13,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -25,6 +27,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -34,6 +37,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -43,6 +47,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -52,6 +57,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -61,6 +67,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -70,6 +77,7 @@
},
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -79,6 +87,7 @@
},
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -88,6 +97,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -130,4 +140,4 @@
"vm" : ["Stop", "Start"],
"vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
-} \ No newline at end of file
+}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json
index e1475ef6c..826603849 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json
@@ -1,6 +1,3 @@
-
-
-
{
"request-info": {
"action": "Restart",
@@ -16,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
- "vserver-id" : "be_vserverid1"
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1"
}
]
}
@@ -35,4 +34,3 @@
}
}
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json
index 984128f9d..07a389f9d 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json
@@ -13,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -25,6 +27,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -34,6 +37,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -43,6 +47,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -52,6 +57,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -62,6 +68,7 @@
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -71,6 +78,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json
index 312c0f542..9053c16ba 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json
@@ -1,7 +1,5 @@
-
-
{
- "request-info": {
+"request-info": {
"action": "Start",
"action-level": "vnf",
"action-identifier": {
@@ -15,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -27,6 +27,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -36,6 +37,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -45,6 +47,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -54,6 +57,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -63,6 +67,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -72,6 +77,7 @@
},
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -80,6 +86,7 @@
},
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -89,6 +96,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -137,5 +145,3 @@
"vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json
index 80c9ff501..5f8efc49d 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json
@@ -1,15 +1,15 @@
-
-
{
- "inventory-info": {
+"inventory-info": {
"vnf-info": {
"vnf-id" : "abc",
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -19,6 +19,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -28,6 +29,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id2",
"vnfc":
{
"vnfc-type": "FE",
@@ -37,6 +39,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id2",
"vnfc":
{
"vnfc-type": "BE",
@@ -46,6 +49,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id3",
"vnfc":
{
"vnfc-type": "BE",
@@ -55,6 +59,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id3",
"vnfc":
{
"vnfc-type": "SMP",
@@ -64,6 +69,7 @@
},
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id2",
"vnfc":
{
"vnfc-type": "SMP",
@@ -72,6 +78,7 @@
},
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id4",
"vnfc":
{
"vnfc-type": "BE",
@@ -81,6 +88,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id5",
"vnfc":
{
"vnfc-type": "BE",
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json
index 1b5ee9477..4a1975b2f 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json
@@ -1,5 +1,3 @@
-
-
{
"request-info": {
"action": "Start",
@@ -15,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -27,6 +27,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -36,6 +37,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -45,6 +47,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -54,6 +57,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -63,6 +67,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -72,6 +77,7 @@
},
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -80,6 +86,7 @@
},
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -89,6 +96,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -137,5 +145,3 @@
"vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json
index 5b44097ff..bd8167202 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json
@@ -1,5 +1,3 @@
-
-
{
"request-info": {
"action": "Restart",
@@ -16,9 +14,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -27,6 +27,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -36,6 +37,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -45,6 +47,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -93,5 +96,3 @@
"vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-single-vm.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-single-vm.json
index 4e5a9a118..65916bb6d 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-single-vm.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-single-vm.json
@@ -1,56 +1,42 @@
+
{
- "request-info":
- {
+ "request-info": {
"action": "Start",
"action-level": "vm",
- "action-identifier":
- {
+ "action-identifier": {
"vserver-id": "dbgx0001v"
},
"payload": "ABC"
},
- "inventory-info":
- {
- "vnf-info":
- {
+ "inventory-info": {
+ "vnf-info": {
"vnf-id" : "abc",
- "vnf-name": "vVNF",
- "vnf-type": "vVNF",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
"vnf-version" : "1.0",
- "vm":
- [
+ "identity-url" : "test_url",
+ "vm": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm-id1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
}
- ]
+ ]
}
},
- "dependency-info":
- {
+ "dependency-info": {
},
- "tunable-parameters":
- {
+ "tunable-parameters": {
},
- "capabilities" :
- {
- "vm" :
- [
- "Stop",
- "Start"
- ],
- "vnfc":
- [
- "StopApplication",
- "StartApplication",
- "HealthCheck"
- ]
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json
index acc6b9c02..65916bb6d 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json
@@ -1,42 +1,43 @@
-
{
- "request-info": {
- "action": "Start",
- "action-level": "vm",
- "action-identifier": {
- "vserver-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
- }
- ]
- }
- },
- "dependency-info": {
+ "request-info": {
+ "action": "Start",
+ "action-level": "vm",
+ "action-identifier": {
+ "vserver-id": "dbgx0001v"
+ },
+ "payload": "ABC"
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm-id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ }
+ ]
+ }
+ },
+ "dependency-info": {
- },
- "tunable-parameters": {
+ },
+ "tunable-parameters": {
- },
- "capabilities" : {
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ },
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json
index 4ec59c245..b9a93cdd8 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json
@@ -1,51 +1,53 @@
{
- "request-info": {
- "action": "Start",
- "action-level": "vm",
- "action-identifier": {
- "vserver-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
- },
- {
- "vserver-id" : "smp_vserverid1",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
+ "request-info": {
+ "action": "Start",
+ "action-level": "vm",
+ "action-identifier": {
+ "vserver-id": "dbgx0001v"
+ },
+ "payload": "ABC"
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm-id",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+ },
+ {
+ "vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm-id",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
- }
- ]
- }
- },
- "dependency-info": {
+ }
+ ]
+ }
+ },
+ "dependency-info": {
- },
- "tunable-parameters": {
+ },
+ "tunable-parameters": {
- },
- "capabilities" : {
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ },
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json
index b1a58e3a1..ea9e7aa6c 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json
@@ -1,114 +1,124 @@
{
- "request-info": {
- "action": "Start",
- "action-level": "vm",
- "action-identifier": {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ "request-info": {
+ "action": "Start",
+ "action-level": "vm",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": "ABC"
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "fe_vserverid1",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "fe_vserverid2",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid2",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid3",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "smp_vserverid1",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
+ },
+ {
+ "vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
- },
- {
- "vserver-id" : "smp_vserverid2",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
- },
- {
- "vserver-id" : "be_vserverid4",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+ },
+ {
+ "vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid5",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info": {
+ }
+ ]
+ }
+ },
+ "dependency-info": {
- },
- "tunable-parameters": {
+ },
+ "tunable-parameters": {
- },
- "capabilities" : {
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ },
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start.json
index 5dc584d4d..e806cd460 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start.json
@@ -1,142 +1,149 @@
-
{
- "request-info": {
- "action": "Start",
- "action-level": "vnf",
- "action-identifier": {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
+ "request-info": {
+ "action": "Start",
+ "action-level": "vnf",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "fe_vserverid1",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "fe_vserverid2",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid2",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid3",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "smp_vserverid1",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
+ },
+ {
+ "vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
- },
- {
- "vserver-id" : "smp_vserverid2",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
- },
- {
- "vserver-id" : "be_vserverid4",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+ },
+ {
+ "vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid5",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info": {
- "vnfcs" : [
- {
- "vnfc-type" : "BE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "SMP"
- ]
- },
- {
- "vnfc-type" : "FE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "BE"
- ]
- },
- {
- "vnfc-type" : "SMP",
- "mandatory" : "true",
- "resilience": "Active-Passive",
- "parents" : []
- }
- ]
- },
- "tunable-parameters": {
- "strategy" : "FORWARD",
- "wait-time": "120",
- "retry-count": "5"
- },
- "capabilities" : {
- "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
- "vf-module": ["Stop", "Start"],
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ }
+ ]
+ }
+ },
+ "dependency-info": {
+ "vnfcs" : [
+ {
+ "vnfc-type" : "BE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "SMP"
+ ]
+ },
+ {
+ "vnfc-type" : "FE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "BE"
+ ]
+ },
+ {
+ "vnfc-type" : "SMP",
+ "mandatory" : "true",
+ "resilience": "Active-Passive",
+ "parents" : []
+ }
+ ]
+ },
+ "tunable-parameters": {
+ "strategy" : "FORWARD",
+ "wait-time": "120",
+ "retry-count": "5"
+ },
+ "capabilities" : {
+ "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
+ "vf-module": ["Stop", "Start"],
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json
index 137a67c19..3251106e3 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json
@@ -16,9 +16,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -28,6 +30,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm-id2",
"vnfc":
{
"vnfc-type": "FE",
@@ -37,6 +40,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm-id3",
"vnfc":
{
"vnfc-type": "FE",
@@ -46,6 +50,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm-id4",
"vnfc":
{
"vnfc-type": "BE",
@@ -55,6 +60,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -64,6 +70,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -73,6 +80,7 @@
},
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -81,6 +89,7 @@
},
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -90,6 +99,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm-id1",
"vnfc":
{
"vnfc-type": "BE",
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm-per-vnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm-per-vnfc.json
index 1d2cfde0e..ed449fe25 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm-per-vnfc.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm-per-vnfc.json
@@ -1,65 +1,51 @@
+
+
{
- "request-info":
- {
+ "request-info": {
"action": "Stop",
"action-level": "vm",
- "action-identifier":
- {
+ "action-identifier": {
"vserver-id": "dbgx0001v"
},
"payload": "ABC"
},
- "inventory-info":
- {
- "vnf-info":
- {
+ "inventory-info": {
+ "vnf-info": {
"vnf-id" : "abc",
- "vnf-name": "vVNF",
- "vnf-type": "vVNF",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
"vnf-version" : "1.0",
- "vm":
- [
+ "identity-url" : "test_url",
+ "vm": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid1",
+ "vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
}
]
}},
- "dependency-info":
- {
+ "dependency-info": {
},
- "tunable-parameters":
- {
+ "tunable-parameters": {
},
- "capabilities" :
- {
- "vm" :
- [
- "Stop",
- "Start"
- ],
- "vnfc":
- [
- "StopApplication",
- "StartApplication",
- "HealthCheck"
- ]
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm.json
index 99abb7a70..02cd56230 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-single-vm.json
@@ -1,56 +1,43 @@
+
+
{
- "request-info":
- {
+ "request-info": {
"action": "Stop",
"action-level": "vm",
- "action-identifier":
- {
+ "action-identifier": {
"vserver-id": "dbgx0001v"
},
"payload": "ABC"
},
- "inventory-info":
- {
- "vnf-info":
- {
+ "inventory-info": {
+ "vnf-info": {
"vnf-id" : "abc",
- "vnf-name": "vVNF",
- "vnf-type": "vVNF",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
"vnf-version" : "1.0",
- "vm":
- [
+ "identity-url" : "test-url",
+ "vm": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
}
]
}
},
- "dependency-info":
- {
+ "dependency-info": {
},
- "tunable-parameters":
- {
+ "tunable-parameters": {
},
- "capabilities" :
- {
- "vm" :
- [
- "Stop",
- "Start"
- ],
- "vnfc":
- [
- "StopApplication",
- "StartApplication",
- "HealthCheck"
- ]
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json
index 30b936585..6cdd3de20 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json
@@ -1,5 +1,3 @@
-
-
{
"request-info": {
"action": "Stop",
@@ -15,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test-url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -38,5 +38,3 @@
"vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json
index 61d9630ab..a49b70403 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json
@@ -1,5 +1,3 @@
-
-
{
"request-info": {
"action": "Stop",
@@ -15,9 +13,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test_url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -26,6 +26,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -46,5 +47,3 @@
"vnfc": ["StopApplication", "StartApplication","HealthCheck"]
}
}
-
-
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop.json
index 0b7a1a7c1..e52269ec0 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop.json
@@ -16,9 +16,11 @@
"vnf-name": "vSCP",
"vnf-type": "vSCP",
"vnf-version" : "1.0",
+ "identity-url" : "test-url",
"vm": [
{
"vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -28,6 +30,7 @@
},
{
"vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -37,6 +40,7 @@
},
{
"vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "FE",
@@ -46,6 +50,7 @@
},
{
"vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -55,6 +60,7 @@
},
{
"vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -64,6 +70,7 @@
},
{
"vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -73,6 +80,7 @@
},
{
"vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "SMP",
@@ -81,6 +89,7 @@
},
{
"vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
@@ -90,6 +99,7 @@
},
{
"vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
"vnfc":
{
"vnfc-type": "BE",
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json
index cd6eaa779..276d550e5 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json
@@ -1,141 +1,151 @@
{
- "request-info": {
- "action": "start",
- "action-level": "vnf",
- "action-identifier": {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "fe_vserverid1",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
-
- },
- {
- "vserver-id" : "fe_vserverid2",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid2",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid3",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "smp_vserverid1",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
-
- },
- {
- "vserver-id" : "smp_vserverid2",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
- },
- {
- "vserver-id" : "be_vserverid4",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ "request-info": {
+ "action": "start",
+ "action-level": "vnf",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": "ABC"
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+ },
+ {
+ "vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid5",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info": {
- "vnfcs" : [
- {
- "vnfc-type" : "BE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "SMP"
- ]
- },
- {
- "vnfc-type" : "FE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "BE"
- ]
- },
- {
- "vnfc-type" : "SMP",
- "mandatory" : "true",
- "resilience": "Active-Passive",
- "parents" : []
- }
- ]
- },
- "tunable-parameters": {
- "strategy" : "FORWARD",
- "wait-time": "120",
- "retry-count": "5"
- },
- "capabilities" : {
- "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
- "vf-module": ["Stop", "Start"],
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ }
+ ]
+ }
+ },
+ "dependency-info": {
+ "vnfcs" : [
+ {
+ "vnfc-type" : "BE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "SMP"
+ ]
+ },
+ {
+ "vnfc-type" : "FE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "BE"
+ ]
+ },
+ {
+ "vnfc-type" : "SMP",
+ "mandatory" : "true",
+ "resilience": "Active-Passive",
+ "parents" : []
+ }
+ ]
+ },
+ "tunable-parameters": {
+ "strategy" : "FORWARD",
+ "wait-time": "120",
+ "retry-count": "5"
+ },
+ "capabilities" : {
+ "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
+ "vf-module": ["Stop", "Start"],
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongnumber.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongnumber.json
index ffdaec28a..6c2db0898 100644
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongnumber.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongnumber.json
@@ -1,141 +1,151 @@
{
- "request-info": {
- "action": "Start",
- "action-level": "vnf",
- "action-identifier": {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info": {
- "vnf-info": {
- "vnf-id" : "abc",
- "vnf-name": "vSCP",
- "vnf-type": "vSCP",
- "vnf-version" : "1.0",
- "vm": [
- {
- "vserver-id" : "be_vserverid1",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "fe_vserverid1",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
-
- },
- {
- "vserver-id" : "fe_vserverid2",
- "vnfc":
- {
- "vnfc-type": "FE",
- "vnfc-name": "FE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid2",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "be_vserverid3",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
-
- },
- {
- "vserver-id" : "smp_vserverid1",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
-
- },
- {
- "vserver-id" : "smp_vserverid2",
- "vnfc":
- {
- "vnfc-type": "SMP",
- "vnfc-name": "SMP - Name"
- }
- },
- {
- "vserver-id" : "be_vserverid4",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ "request-info": {
+ "action": "Start",
+ "action-level": "vnf",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": "ABC"
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "identity-url" : "test_url",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "fe_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid3",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "smp_vserverid1",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "smp_vserverid2",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+ },
+ {
+ "vserver-id" : "be_vserverid4",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "be_vserverid5",
- "vnfc":
- {
- "vnfc-type": "BE",
- "vnfc-name": "BE - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vm-id" : "vm_id1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info": {
- "vnfcs" : [
- {
- "vnfc-type" : "BE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "SMP"
- ]
- },
- {
- "vnfc-type" : "FE",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" : [
- "BE"
- ]
- },
- {
- "vnfc-type" : "SMP",
- "mandatory" : "true",
- "resilience": "Active-Passive",
- "parents" : []
- }
- ]
- },
- "tunable-parameters": {
- "strategy" : "FORWARD",
- "wait-time": "6a",
- "retry-count": "5"
- },
- "capabilities" : {
- "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
- "vf-module": ["Stop", "Start"],
- "vm" : ["Stop", "Start"],
- "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
- }
+ }
+ ]
+ }
+ },
+ "dependency-info": {
+ "vnfcs" : [
+ {
+ "vnfc-type" : "BE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "SMP"
+ ]
+ },
+ {
+ "vnfc-type" : "FE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "BE"
+ ]
+ },
+ {
+ "vnfc-type" : "SMP",
+ "mandatory" : "true",
+ "resilience": "Active-Passive",
+ "parents" : []
+ }
+ ]
+ },
+ "tunable-parameters": {
+ "strategy" : "FORWARD",
+ "wait-time": "6a",
+ "retry-count": "5"
+ },
+ "capabilities" : {
+ "vnf": ["Stop", "Start", "StartApplication","StopApplication"],
+ "vf-module": ["Stop", "Start"],
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
}
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json
index df6f7b93d..34c464d63 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json
@@ -1 +1 @@
-[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"jump":"3"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"jump":"3"}}]},{"transactionId":3,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"jump":"5"}}]},{"transactionId":4,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"jump":"5"}}]},{"transactionId":5,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"jump":"7"}}]},{"transactionId":6,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"jump":"7"}}]},{"transactionId":7,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[]},{"transactionId":8,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[]}] \ No newline at end of file
+[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"jump":"3"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"jump":"3"}}]},{"transactionId":3,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"jump":"5"}}]},{"transactionId":4,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"jump":"5"}}]},{"transactionId":5,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"jump":"7"}}]},{"transactionId":6,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"jump":"7"}}]},{"transactionId":7,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[]},{"transactionId":8,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-Nodep-SingleVM.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-Nodep-SingleVM.json
index c3e2a7449..043ab63b0 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-Nodep-SingleVM.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-Nodep-SingleVM.json
@@ -1,4 +1,2 @@
+[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[]}]
-
-
-[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVM-.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVM-.json
index dbacc77d8..f883f1d96 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVM-.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVM-.json
@@ -1,3 +1 @@
-
-
-[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[]}]
+[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm-id1\"}","responses":[]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json
index 5d43c4b7b..6ee628050 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json
@@ -1,3 +1 @@
-
-
-[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
+[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm-id\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm-id\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json
index 64f9f467f..16d03d245 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json
@@ -1 +1 @@
-[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":3,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":4,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":5,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid3"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":6,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":7,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":8,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid4"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":9,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}] \ No newline at end of file
+[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":3,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":4,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":5,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid3"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":6,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":7,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":8,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid4"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":9,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json
index f35e58c1b..625ed211b 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json
@@ -1,3 +1 @@
-
-
-[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid1"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":3,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":4,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":5,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid3"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":6,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":7,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":8,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid4"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":9,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
+[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid1"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id2\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":3,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id3\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":4,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id4\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":5,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid3"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":6,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":7,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":8,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid4"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":9,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid5"},"payload":"{\"identity-url\":\"test\",\"vm-id\":\"vm-id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json
index 50447feca..4edd30914 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json
@@ -1,3 +1 @@
-
-
-[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[]}]
+[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test-url\",\"vm-id\":\"vm_id1\"}","responses":[]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json
index 8830c0955..94905af90 100755
--- a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json
@@ -1,3 +1 @@
-
-
-[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
+[{"transactionId":1,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Stop","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"{\"identity-url\":\"test_url\",\"vm-id\":\"vm_id1\"}","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-model/src/main/yang/sequence-generator.yang b/appc-sequence-generator/appc-sequence-generator-model/src/main/yang/sequence-generator.yang
index 6da825195..f9bd92150 100644
--- a/appc-sequence-generator/appc-sequence-generator-model/src/main/yang/sequence-generator.yang
+++ b/appc-sequence-generator/appc-sequence-generator-model/src/main/yang/sequence-generator.yang
@@ -86,12 +86,18 @@ module sequence-generator {
leaf vnf-type {
type string;
}
+ leaf identity-url {
+ type string;
+ }
list vm {
ordered-by user;
key "vserver-id";
leaf vserver-id {
type string;
}
+ leaf vm-id {
+ type string;
+ }
container vnfc {
leaf vnfc-type {
type string;