aboutsummaryrefslogtreecommitdiffstats
path: root/appc-sequence-generator/appc-sequence-generator-bundle/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'appc-sequence-generator/appc-sequence-generator-bundle/src/test')
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/java/org/onap/appc/seqgen/TestSequenceGeneratorPlugin.java146
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json124
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json133
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json38
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json117
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json155
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json147
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json150
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json97
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json42
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json51
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json114
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start.json310
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json142
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json42
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json50
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop.json153
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json321
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongnumber.json321
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Output-stop.json3
-rw-r--r--appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Start.json2
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json1
-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-.json3
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json3
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json1
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json3
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json3
-rwxr-xr-xappc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json3
29 files changed, 1694 insertions, 985 deletions
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 748773a21..1fde88831 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
@@ -51,15 +51,29 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/start.json");
+ String actualOutput = readOutput("/output/Start.json");
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
+ @Test
+ public void testGenerateSequenceWODependencyInfo()throws URISyntaxException, IOException {
+ String inputJSON = readInput("/input/start-withoutDependency.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/start-withoutDependency.json");
+ Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
+ }
@Test
public void testGenerateSequenceSingleVM()throws URISyntaxException, IOException {
- String inputJSON = readInput("/input/start-single-vm.json");
+ String inputJSON = readInput("/input/start-singleVM-.json");
Map<String,String> params = new HashMap<>();
SvcLogicContext context = new SvcLogicContext();
@@ -69,7 +83,7 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/start-single-vm.json");
+ String actualOutput = readOutput("/output/start-singleVM-.json");
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
@@ -85,7 +99,7 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/start.json");
+ String actualOutput = readOutput("/output/Start.json");
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
@@ -102,7 +116,7 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/stop.json");
+ String actualOutput = readOutput("/output/Output-stop.json");
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
@@ -144,7 +158,6 @@ public class TestSequenceGeneratorPlugin {
Assert.assertEquals(errorMessage,"Error generating sequence There seems to be no Root/Independent node for Vnfc dependencies");
}
-
@Test
public void testGenerateSequenceWrongAction() throws URISyntaxException, IOException {
String inputJSON = readInput("/input/wrongaction.json");
@@ -184,7 +197,7 @@ public class TestSequenceGeneratorPlugin {
@Test
public void testGenerateSequenceStopSingleVM() throws URISyntaxException, IOException{
- String inputJSON = readInput("/input/stop-single-vm.json");
+ String inputJSON = readInput("/input/stop-singleVM.json");
Map<String,String> params = new HashMap<>();
SvcLogicContext context = new SvcLogicContext();
@@ -194,13 +207,29 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/stop-single-vm.json");
+ String actualOutput = readOutput("/output/stop-singleVM.json");
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
@Test
public void testGenerateSequenceStopSingleVmPerVnfc() throws URISyntaxException, IOException{
- String inputJSON = readInput("/input/stop-single-vm-per-vnfc.json");
+ String inputJSON = readInput("/input/stop-singleVmPerVnfc.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-singleVmPerVnfc.json");
+ Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
+ }
+
+ @Test
+ public void testGenerateSequenceRestartNoDep() throws URISyntaxException, IOException {
+ String inputJSON = readInput("/input/restartNodep.json");
Map<String,String> params = new HashMap<>();
SvcLogicContext context = new SvcLogicContext();
@@ -210,13 +239,30 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/stop-single-vm-per-vnfc.json");
+ String actualOutput = readInput("/output/restart-NoDep.json");
+ outputJSON.trim();
+ Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
+ }
+
+ @Test
+ public void testGenerateSequenceRestartNoDepSingleVM() throws URISyntaxException, IOException {
+ String inputJSON = readInput("/input/NoDep-SingleVM.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 = readInput("/output/restart-Nodep-SingleVM.json");
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
@Test
public void testGenerateSequenceStartSingleVmPerVnfc() throws URISyntaxException, IOException{
- String inputJSON = readInput("/input/start-single-vm-per-vnfc.json");
+ String inputJSON = readInput("/input/start-singleVmPerVnfc-.json");
Map<String,String> params = new HashMap<>();
SvcLogicContext context = new SvcLogicContext();
@@ -226,7 +272,24 @@ public class TestSequenceGeneratorPlugin {
plugin.generateSequence(params,context);
String outputJSON = context.getAttribute("output");
- String actualOutput = readOutput("/output/start-single-vm-per-vnfc.json");
+ String actualOutput = readOutput("/output/start-singleVmPerVnfc.json");
+ Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
+ }
+
+ @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());
}
@@ -246,6 +309,60 @@ public class TestSequenceGeneratorPlugin {
Assert.assertEquals(outputJSON.trim(),actualOutput.trim());
}
+ @Test
+ public void testGenerateSequenceCheckMandatoryVnfc() throws URISyntaxException, IOException {
+ String inputJSON = readInput("/input/CheckMandatoryVnfc.json");
+
+ Map<String,String> params = new HashMap<>();
+ SvcLogicContext context = new SvcLogicContext();
+ context.setAttribute("inputJSON",inputJSON);
+
+ SequenceGeneratorPlugin plugin = new SequenceGeneratorPluginImpl();
+ plugin.generateSequence(params,context);
+
+ String errorCode = context.getAttribute("error-code");
+ String errorMessage = context.getAttribute("error-message");
+ logger.debug("errorCode = " + errorCode);
+ Assert.assertEquals(errorCode,"401");
+ Assert.assertEquals(errorMessage,"Error generating sequence VMs missing for the mandatory VNFC : [smp]");
+ }
+
+ @Test
+ public void testGenerateSequenceCheckMissingDependencyInfo() throws URISyntaxException, IOException {
+ String inputJSON = readInput("/input/MissingDependencyInfo.json");
+
+ Map<String,String> params = new HashMap<>();
+ SvcLogicContext context = new SvcLogicContext();
+ context.setAttribute("inputJSON",inputJSON);
+
+ SequenceGeneratorPlugin plugin = new SequenceGeneratorPluginImpl();
+ plugin.generateSequence(params,context);
+
+ String errorCode = context.getAttribute("error-code");
+ String errorMessage = context.getAttribute("error-message");
+ logger.debug("errorCode = " + errorCode);
+ Assert.assertEquals(errorCode,"401");
+ Assert.assertEquals(errorMessage,"Error generating sequence Dependency model is missing following vnfc type(s): [smp]");
+ }
+
+ @Test
+ public void testGenerateSequenceExtraVnfcInDependency() throws URISyntaxException, IOException {
+ String inputJSON = readInput("/input/WrongDependencyModel.json");
+
+ Map<String,String> params = new HashMap<>();
+ SvcLogicContext context = new SvcLogicContext();
+ context.setAttribute("inputJSON",inputJSON);
+
+ SequenceGeneratorPlugin plugin = new SequenceGeneratorPluginImpl();
+ plugin.generateSequence(params,context);
+
+ String errorCode = context.getAttribute("error-code");
+ String errorMessage = context.getAttribute("error-message");
+ logger.debug("errorCode = " + errorCode);
+ Assert.assertEquals(errorCode,"401");
+ Assert.assertEquals(errorMessage,"Error generating sequence Dependency model missing vnfc type SMP");
+ }
+
private String readInput(String inputFile) throws URISyntaxException, IOException {
File file = new File(this.getClass().getResource(inputFile).toURI());
@@ -262,11 +379,10 @@ public class TestSequenceGeneratorPlugin {
FileInputStream fileInputStream = new FileInputStream(file);
fileInputStream.read(bFile);
fileInputStream.close();
-
String output=new String(bFile);
int start=output.indexOf("[");
- int last=output.length();
- return output.substring(start,last);
+ return output.substring(start,output.length());
}
}
+
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
new file mode 100644
index 000000000..8af3e7332
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/CheckMandatoryVnfc.json
@@ -0,0 +1,124 @@
+{
+ "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"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "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"]
+ }
+}
+
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
new file mode 100644
index 000000000..667565d0a
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/MissingDependencyInfo.json
@@ -0,0 +1,133 @@
+{
+ "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"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ }
+ ]
+ }
+ },
+ "dependency-info": {
+ "vnfcs" : [
+ {
+ "vnfc-type" : "BE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+
+ ]
+ },
+ {
+ "vnfc-type" : "FE",
+ "mandatory" : "true",
+ "resilience": "Active-Active",
+ "parents" : [
+ "BE"
+ ]
+ }
+
+ ]
+ },
+ "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"]
+ }
+} \ 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
new file mode 100755
index 000000000..e1475ef6c
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/NoDep-SingleVM.json
@@ -0,0 +1,38 @@
+
+
+
+{
+ "request-info": {
+ "action": "Restart",
+ "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"
+ }
+ ]
+ }
+ },
+ "dependency-info" : {
+
+ },
+ "tunable-parameters" : {
+
+ },
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "vnfc": ["StopApplication", "StartApplication","HealthCheck"]
+ }
+}
+
+
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
new file mode 100755
index 000000000..984128f9d
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/WrongDependencyModel.json
@@ -0,0 +1,117 @@
+{
+ "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"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "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"
+ ]
+ }
+
+ ]
+ },
+ "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/cyclic.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/cyclic.json
index 522b99692..312c0f542 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,197 +1,140 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "request-info":
- {
+ "request-info": {
"action": "Start",
"action-level": "vnf",
- "action-identifier":
- {
+ "action-identifier": {
"vnf-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": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid1",
+ "vserver-id" : "fe_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid2",
+ "vserver-id" : "fe_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid2",
+ "vserver-id" : "be_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid3",
+ "vserver-id" : "be_vserverid3",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid1",
+ "vserver-id" : "smp_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid2",
+ "vserver-id" : "smp_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid4",
+ "vserver-id" : "be_vserverid4",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid5",
+ "vserver-id" : "be_vserverid5",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
}
]
}
},
- "dependency-info" :
- {
- "vnfcs" :
- [
+ "dependency-info" : {
+ "vnfcs" : [
{
- "vnfc-type" : "VNFC2",
+ "vnfc-type" : "BE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
+ "parents" : [
+ "SMP"
]
},
{
- "vnfc-type" : "VNFC3",
+ "vnfc-type" : "FE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
+ "parents" : [
+ "BE"
]
},
{
- "vnfc-type" : "VNFC1",
+ "vnfc-type" : "SMP",
"mandatory" : "true",
"resilience": "Active-Passive",
- "parents" :
- [
- "VNFC3"
- ]
+ "parents" : ["FE"]
}
]
},
- "tunable-parameters" :
- {
+ "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"
- ]
+ "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/missingrequestinfo.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/missingrequestinfo.json
index c5bc7ead2..80c9ff501 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,185 +1,132 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "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":
- [
+ "vm": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid1",
+ "vserver-id" : "fe_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid2",
+ "vserver-id" : "fe_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid2",
+ "vserver-id" : "be_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid3",
+ "vserver-id" : "be_vserverid3",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid1",
+ "vserver-id" : "smp_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid2",
+ "vserver-id" : "smp_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid4",
+ "vserver-id" : "be_vserverid4",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid5",
+ "vserver-id" : "be_vserverid5",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
}
]
}
},
- "dependency-info":
- {
- "vnfcs" :
- [
+ "dependency-info": {
+ "vnfcs" : [
{
- "vnfc-type" : "VNFC2",
+ "vnfc-type" : "BE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
+ "parents" : [
+ "SMP"
]
},
{
- "vnfc-type" : "VNFC3",
+ "vnfc-type" : "FE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
+ "parents" : [
+ "BE"
]
},
{
- "vnfc-type" : "VNFC1",
+ "vnfc-type" : "SMP",
"mandatory" : "true",
"resilience": "Active-Passive",
"parents" : []
}
]
},
- "tunable-parameters":
- {
+ "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"
- ]
+ "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/no-strategy.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/no-strategy.json
index 1371d2273..1b5ee9477 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,194 +1,140 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "request-info":
- {
+ "request-info": {
"action": "Start",
"action-level": "vnf",
- "action-identifier":
- {
+ "action-identifier": {
"vnf-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": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid1",
+ "vserver-id" : "fe_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid2",
+ "vserver-id" : "fe_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid2",
+ "vserver-id" : "be_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid3",
+ "vserver-id" : "be_vserverid3",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid1",
+ "vserver-id" : "smp_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid2",
+ "vserver-id" : "smp_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid4",
+ "vserver-id" : "be_vserverid4",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid5",
+ "vserver-id" : "be_vserverid5",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
}
]
}
},
- "dependency-info":
- {
- "vnfcs" :
- [
+ "dependency-info": {
+ "vnfcs" : [
{
- "vnfc-type" : "VNFC2",
+ "vnfc-type" : "BE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
+ "parents" : [
+ "SMP"
]
},
{
- "vnfc-type" : "VNFC3",
+ "vnfc-type" : "FE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
+ "parents" : [
+ "BE"
]
},
{
- "vnfc-type" : "VNFC1",
+ "vnfc-type" : "SMP",
"mandatory" : "true",
"resilience": "Active-Passive",
"parents" : []
}
]
},
- "tunable-parameters":
- {
+ "tunable-parameters": {
"strategy" : "",
"wait-time": "120",
"retry-count": "5"
},
- "capabilities" :
- {
- "vnf":
- [
- "Stop",
- "Start",
- "StartApplication",
- "StopApplication"
- ],
- "vf-module":
- [
- "Stop",
- "Start"
- ],
- "vm" :
- [
- "Stop",
- "Start"
- ],
- "vnfc":
- [
- "StopApplication",
- "StartApplication",
- "HealthCheck"
- ]
+ "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/restartNodep.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json
new file mode 100755
index 000000000..5b44097ff
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/restartNodep.json
@@ -0,0 +1,97 @@
+
+
+{
+ "request-info": {
+ "action": "Restart",
+ "action-level": "vm",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": " {\"vnf-host-ip-address\": \"10.147.124.163\" }"
+
+ },
+ "inventory-info": {
+ "vnf-info": {
+ "vnf-id" : "abc",
+ "vnf-name": "vSCP",
+ "vnf-type": "vSCP",
+ "vnf-version" : "1.0",
+ "vm": [
+ {
+ "vserver-id" : "smp_vserverid2",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "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",
+ "waitTime" : "120",
+ "retryCount" : "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/start-singleVM-.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json
new file mode 100755
index 000000000..acc6b9c02
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVM-.json
@@ -0,0 +1,42 @@
+
+
+{
+ "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": {
+
+ },
+ "tunable-parameters": {
+
+ },
+ "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
new file mode 100755
index 000000000..4ec59c245
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-singleVmPerVnfc-.json
@@ -0,0 +1,51 @@
+
+
+{
+ "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"
+ }
+
+ }
+ ]
+ }
+ },
+ "dependency-info": {
+
+ },
+ "tunable-parameters": {
+
+ },
+ "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
new file mode 100755
index 000000000..b1a58e3a1
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/start-withoutDependency.json
@@ -0,0 +1,114 @@
+
+
+{
+ "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"
+ }
+
+ },
+ {
+ "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"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
+
+ }
+ ]
+ }
+ },
+ "dependency-info": {
+
+ },
+ "tunable-parameters": {
+
+ },
+ "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 143b41d23..5dc584d4d 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,196 +1,142 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "request-info":
- {
- "action": "Start",
- "action-level": "vnf",
- "action-identifier":
- {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info":
- {
- "vnf-info":
- {
- "vnf-id" : "abc",
- "vnf-name": "vVNF",
- "vnf-type": "vVNF",
- "vnf-version" : "1.0",
- "vm":
- [
- {
- "vserver-id" : "vnfc2_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - 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",
+ "vm": [
+ {
+ "vserver-id" : "be_vserverid1",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "vnfc3_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid1",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "vnfc3_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
- }
+ },
+ {
+ "vserver-id" : "fe_vserverid2",
+ "vnfc":
+ {
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
+ }
- },
- {
- "vserver-id" : "vnfc2_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid2",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "vnfc2_vserverid3",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid3",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- },
- {
- "vserver-id" : "vnfc1_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
- }
+ },
+ {
+ "vserver-id" : "smp_vserverid1",
+ "vnfc":
+ {
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
+ }
- },
- {
- "vserver-id" : "vnfc1_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
- }
- },
- {
- "vserver-id" : "vnfc2_vserverid4",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - 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" : "vnfc2_vserverid5",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info" :
- {
- "vnfcs" :
- [
- {
- "vnfc-type" : "VNFC2",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
- ]
- },
- {
- "vnfc-type" : "VNFC3",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
- ]
- },
- {
- "vnfc-type" : "VNFC1",
- "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
new file mode 100755
index 000000000..137a67c19
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-WithoutDep.json
@@ -0,0 +1,142 @@
+
+
+{
+ "request-info": {
+ "action": "Stop",
+ "action-level": "vm",
+ "action-identifier": {
+ "vnf-id": "dbgx0001v"
+ },
+ "payload": " {\"vnf-host-ip-address\": \"10.147.124.163\" }"
+
+ },
+ "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"
+ }
+
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "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"]
+ }
+}
+
+
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
new file mode 100755
index 000000000..30b936585
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVM.json
@@ -0,0 +1,42 @@
+
+
+{
+ "request-info": {
+ "action": "Stop",
+ "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": {
+
+ },
+ "tunable-parameters": {
+
+ },
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "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
new file mode 100755
index 000000000..61d9630ab
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/stop-singleVmPerVnfc.json
@@ -0,0 +1,50 @@
+
+
+{
+ "request-info": {
+ "action": "Stop",
+ "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"
+ }
+
+ }
+ ]
+ }},
+ "dependency-info": {
+
+ },
+ "tunable-parameters": {
+
+ },
+ "capabilities" : {
+ "vm" : ["Stop", "Start"],
+ "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 9131a652b..0b7a1a7c1 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
@@ -1,196 +1,141 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "request-info":
- {
+ "request-info": {
"action": "Stop",
"action-level": "vnf",
- "action-identifier":
- {
+ "action-identifier": {
"vnf-id": "dbgx0001v"
},
"payload": " {\"vnf-host-ip-address\": \"10.147.124.163\" }"
},
- "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":
- [
+ "vm": [
{
- "vserver-id" : "vnfc2_vserverid1",
+ "vserver-id" : "be_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid1",
+ "vserver-id" : "fe_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc3_vserverid2",
+ "vserver-id" : "fe_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
+ "vnfc-type": "FE",
+ "vnfc-name": "FE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid2",
+ "vserver-id" : "be_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid3",
+ "vserver-id" : "be_vserverid3",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid1",
+ "vserver-id" : "smp_vserverid1",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc1_vserverid2",
+ "vserver-id" : "smp_vserverid2",
"vnfc":
{
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
+ "vnfc-type": "SMP",
+ "vnfc-name": "SMP - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid4",
+ "vserver-id" : "be_vserverid4",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
},
{
- "vserver-id" : "vnfc2_vserverid5",
+ "vserver-id" : "be_vserverid5",
"vnfc":
{
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
}
}
]
}
},
- "dependency-info":
- {
- "vnfcs" :
- [
+ "dependency-info": {
+ "vnfcs" : [
{
- "vnfc-type" : "VNFC2",
+ "vnfc-type" : "BE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
+ "parents" : [
+ "SMP"
]
},
{
- "vnfc-type" : "VNFC3",
+ "vnfc-type" : "FE",
"mandatory" : "true",
"resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
+ "parents" : [
+ "BE"
]
},
{
- "vnfc-type" : "VNFC1",
+ "vnfc-type" : "SMP",
"mandatory" : "true",
"resilience": "Active-Passive",
"parents" : []
}
]
},
- "tunable-parameters":
- {
+ "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"
- ]
+ "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/wrongaction.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/input/wrongaction.json
index 72f6ed87f..cd6eaa779 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,196 +1,141 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "request-info":
- {
- "action": "start",
- "action-level": "vnf",
- "action-identifier":
- {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info":
- {
- "vnf-info":
- {
- "vnf-id" : "abc",
- "vnf-name": "vVNF",
- "vnf-type": "vVNF",
- "vnf-version" : "1.0",
- "vm":
- [
- {
- "vserver-id" : "vnfc2_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc3_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc3_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc2_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc2_vserverid3",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc1_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc1_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
- }
- },
- {
- "vserver-id" : "vnfc2_vserverid4",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - 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",
+ "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"
+ }
- },
- {
- "vserver-id" : "vnfc2_vserverid5",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info":
- {
- "vnfcs" :
- [
- {
- "vnfc-type" : "VNFC2",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
- ]
- },
- {
- "vnfc-type" : "VNFC3",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
- ]
- },
- {
- "vnfc-type" : "VNFC1",
- "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 958df0379..ffdaec28a 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,196 +1,141 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP : APPC
- * ================================================================================
- * Copyright (C) 2017 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
- *
- * 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.
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
- * ============LICENSE_END=========================================================
- */
-
-
{
- "request-info":
- {
- "action": "Start",
- "action-level": "vnf",
- "action-identifier":
- {
- "vnf-id": "dbgx0001v"
- },
- "payload": "ABC"
- },
- "inventory-info":
- {
- "vnf-info":
- {
- "vnf-id" : "abc",
- "vnf-name": "vVNF",
- "vnf-type": "vVNF",
- "vnf-version" : "1.0",
- "vm":
- [
- {
- "vserver-id" : "vnfc2_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc3_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc3_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC3",
- "vnfc-name": "VNFC3 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc2_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc2_vserverid3",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc1_vserverid1",
- "vnfc":
- {
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
- }
-
- },
- {
- "vserver-id" : "vnfc1_vserverid2",
- "vnfc":
- {
- "vnfc-type": "VNFC1",
- "vnfc-name": "VNFC1 - Name"
- }
- },
- {
- "vserver-id" : "vnfc2_vserverid4",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - 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",
+ "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"
+ }
- },
- {
- "vserver-id" : "vnfc2_vserverid5",
- "vnfc":
- {
- "vnfc-type": "VNFC2",
- "vnfc-name": "VNFC2 - Name"
- }
+ },
+ {
+ "vserver-id" : "be_vserverid5",
+ "vnfc":
+ {
+ "vnfc-type": "BE",
+ "vnfc-name": "BE - Name"
+ }
- }
- ]
- }
- },
- "dependency-info":
- {
- "vnfcs" :
- [
- {
- "vnfc-type" : "VNFC2",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" :
- [
- "VNFC1"
- ]
- },
- {
- "vnfc-type" : "VNFC3",
- "mandatory" : "true",
- "resilience": "Active-Active",
- "parents" :
- [
- "VNFC2"
- ]
- },
- {
- "vnfc-type" : "VNFC1",
- "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/Output-stop.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Output-stop.json
new file mode 100755
index 000000000..17aea0d12
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Output-stop.json
@@ -0,0 +1,3 @@
+
+
+[{"transactionId":1,"action":"StopApplication","action-level":"vnfc","action-identifier":{"vnfc-name":"SMP - Name"},"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":"smp_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":"smp_vserverid2"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":4,"action":"StopApplication","action-level":"vnfc","action-identifier":{"vnfc-name":"BE - Name"},"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_vserverid1"},"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":"be_vserverid2"},"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":"be_vserverid3"},"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":10,"action":"StopApplication","action-level":"vnfc","action-identifier":{"vnfc-name":"FE - Name"},"payload":" {\"vnf-host-ip-address\": \"10.147.124.163\" }","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":11,"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":12,"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"}}]}]
diff --git a/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Start.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Start.json
new file mode 100644
index 000000000..e67f22f56
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/Start.json
@@ -0,0 +1,2 @@
+
+[{"transactionId":1,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":2,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"smp_vserverid2"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":3,"action":"StartApplication","action-level":"vnfc","action-identifier":{"vnfc-name":"SMP - Name"},"payload":"ABC","precheck-operator":"any","precheck-options":[{"pre-transactionID":1,"param-name":"status","param-value":"success"},{"pre-transactionID":2,"param-name":"status","param-value":"success"}],"responses":[]},{"transactionId":4,"action":"HealthCheck","action-level":"vnfc","action-identifier":{"vnfc-name":"SMP - Name"},"payload":"ABC","responses":[{"response-message":"unhealthy","response-action":{"wait":"120","retry":"5"}},{"response-message":"healthy","response-action":{"continue":"true"}},{"response-message":"failure","response-action":{"stop":"true"}}]},{"transactionId":5,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":6,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid2"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":7,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"be_vserverid3"},"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"}}]},{"transactionId":10,"action":"StartApplication","action-level":"vnfc","action-identifier":{"vnfc-name":"BE - Name"},"payload":"ABC","precheck-operator":"any","precheck-options":[{"pre-transactionID":5,"param-name":"status","param-value":"success"},{"pre-transactionID":6,"param-name":"status","param-value":"success"},{"pre-transactionID":7,"param-name":"status","param-value":"success"},{"pre-transactionID":8,"param-name":"status","param-value":"success"},{"pre-transactionID":9,"param-name":"status","param-value":"success"}],"responses":[]},{"transactionId":11,"action":"HealthCheck","action-level":"vnfc","action-identifier":{"vnfc-name":"BE - Name"},"payload":"ABC","responses":[{"response-message":"unhealthy","response-action":{"wait":"120","retry":"5"}},{"response-message":"healthy","response-action":{"continue":"true"}},{"response-message":"failure","response-action":{"stop":"true"}}]},{"transactionId":12,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid1"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":13,"action":"Start","action-level":"vm","action-identifier":{"vserver-id":"fe_vserverid2"},"payload":"ABC","responses":[{"response-message":"failure","response-action":{"ignore":"true"}}]},{"transactionId":14,"action":"StartApplication","action-level":"vnfc","action-identifier":{"vnfc-name":"FE - Name"},"payload":"ABC","precheck-operator":"any","precheck-options":[{"pre-transactionID":12,"param-name":"status","param-value":"success"},{"pre-transactionID":13,"param-name":"status","param-value":"success"}],"responses":[]},{"transactionId":15,"action":"HealthCheck","action-level":"vnfc","action-identifier":{"vnfc-name":"FE - Name"},"payload":"ABC","responses":[{"response-message":"unhealthy","response-action":{"wait":"120","retry":"5"}},{"response-message":"healthy","response-action":{"continue":"true"}},{"response-message":"failure","response-action":{"stop":"true"}}]}]
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
new file mode 100755
index 000000000..df6f7b93d
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-NoDep.json
@@ -0,0 +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
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
new file mode 100755
index 000000000..c3e2a7449
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/restart-Nodep-SingleVM.json
@@ -0,0 +1,4 @@
+
+
+
+[{"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
new file mode 100755
index 000000000..dbacc77d8
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVM-.json
@@ -0,0 +1,3 @@
+
+
+[{"transactionId":1,"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-singleVmPerVnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json
new file mode 100755
index 000000000..5d43c4b7b
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-singleVmPerVnfc.json
@@ -0,0 +1,3 @@
+
+
+[{"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"}}]}]
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
new file mode 100755
index 000000000..64f9f467f
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/start-withoutDependency.json
@@ -0,0 +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
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
new file mode 100755
index 000000000..f35e58c1b
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-WithoutDep.json
@@ -0,0 +1,3 @@
+
+
+[{"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"}}]}]
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
new file mode 100755
index 000000000..50447feca
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVM.json
@@ -0,0 +1,3 @@
+
+
+[{"transactionId":1,"action":"Stop","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/stop-singleVmPerVnfc.json b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json
new file mode 100755
index 000000000..8830c0955
--- /dev/null
+++ b/appc-sequence-generator/appc-sequence-generator-bundle/src/test/resources/output/stop-singleVmPerVnfc.json
@@ -0,0 +1,3 @@
+
+
+[{"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"}}]}]