summaryrefslogtreecommitdiffstats
path: root/components/model-catalog/blueprint-model/uat-blueprints
diff options
context:
space:
mode:
authorgummar <raj.gumma@est.tech>2020-03-03 14:48:22 +0000
committerRaj Gumma <raj.gumma@est.tech>2020-03-03 19:09:27 +0000
commitda1303759f22b7882b46fb8670704f2770bf46ed (patch)
treea9323e18e577f1cb46ddfcb6801bd61e04519c2a /components/model-catalog/blueprint-model/uat-blueprints
parent2fce8bf2891f3ce472f4b06d09d0e987fbc44149 (diff)
Fix case for all Software upgrade actions
Issue-ID: CCSDK-2145 Signed-off-by: gummar <raj.gumma@est.tech> Change-Id: Ie2a6b6c72997be65ac304f6cd1daac3a8aa85480
Diffstat (limited to 'components/model-catalog/blueprint-model/uat-blueprints')
-rw-r--r--components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/PNF_CDS_RESTCONF.json64
-rw-r--r--components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/data_types.json16
-rw-r--r--components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Scripts/kotlin/RestconfSoftwareUpgrade.kt30
-rw-r--r--components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Tests/uat.yaml48
4 files changed, 79 insertions, 79 deletions
diff --git a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/PNF_CDS_RESTCONF.json b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/PNF_CDS_RESTCONF.json
index 2e6c2f547..747fd8c19 100644
--- a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/PNF_CDS_RESTCONF.json
+++ b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/PNF_CDS_RESTCONF.json
@@ -25,22 +25,22 @@
"get_input" : "resolution-key"
}
},
- "precheck-properties" : {
+ "preCheck-properties" : {
"resolution-key" : {
"get_input" : "resolution-key"
}
},
- "downloadNeSw-properties" : {
+ "downloadNESW-properties" : {
"resolution-key" : {
"get_input" : "resolution-key"
}
},
- "activateNeSw-properties" : {
+ "activateNESW-properties" : {
"resolution-key" : {
"get_input" : "resolution-key"
}
},
- "postcheck-properties" : {
+ "postCheck-properties" : {
"resolution-key" : {
"get_input" : "resolution-key"
}
@@ -96,11 +96,11 @@
}
}
},
- "precheck" : {
+ "preCheck" : {
"steps" : {
"activate-process" : {
"description" : "Check if pnf ready for sw upgrade",
- "target" : "precheck",
+ "target" : "preCheck",
"activities" : [ {
"call_operation" : ""
} ]
@@ -111,18 +111,18 @@
"required" : true,
"type" : "string"
},
- "precheck-properties" : {
- "description" : "Dynamic PropertyDefinition for precheck workflow(software-upgrade).",
+ "preCheck-properties" : {
+ "description" : "Dynamic PropertyDefinition for preCheck workflow(software-upgrade).",
"required" : true,
- "type" : "dt-precheck-properties"
+ "type" : "dt-preCheck-properties"
}
}
},
- "downloadNeSw" : {
+ "downloadNESW" : {
"steps" : {
"activate-process" : {
"description" : "Trigger download new software for sw upgrade",
- "target" : "downloadNeSw",
+ "target" : "downloadNESW",
"activities" : [ {
"call_operation" : ""
} ]
@@ -133,18 +133,18 @@
"required" : true,
"type" : "string"
},
- "downloadNeSw-properties" : {
- "description" : "Dynamic PropertyDefinition for downloadNeSw workflow(software-upgrade).",
+ "downloadNESW-properties" : {
+ "description" : "Dynamic PropertyDefinition for downloadNESW workflow(software-upgrade).",
"required" : true,
- "type" : "dt-downloadNeSw-properties"
+ "type" : "dt-downloadNESW-properties"
}
}
},
- "activateNeSw" : {
+ "activateNESW" : {
"steps" : {
"activate-process" : {
"description" : "Trigger activation of target software version for pnf upgrade",
- "target" : "activateNeSw",
+ "target" : "activateNESW",
"activities" : [ {
"call_operation" : ""
} ]
@@ -155,18 +155,18 @@
"required" : true,
"type" : "string"
},
- "activateNeSw-properties" : {
- "description" : "Dynamic PropertyDefinition for activateNeSw workflow(software-upgrade).",
+ "activateNESW-properties" : {
+ "description" : "Dynamic PropertyDefinition for activateNESW workflow(software-upgrade).",
"required" : true,
- "type" : "dt-activateNeSw-properties"
+ "type" : "dt-activateNESW-properties"
}
}
},
- "postcheck" : {
+ "postCheck" : {
"steps" : {
"activate-process" : {
"description" : "Check if pnf upgrade is completed",
- "target" : "postcheck",
+ "target" : "postCheck",
"activities" : [ {
"call_operation" : ""
} ]
@@ -177,10 +177,10 @@
"required" : true,
"type" : "string"
},
- "postcheck-properties" : {
- "description" : "Dynamic PropertyDefinition for postcheck workflow(software-upgrade).",
+ "postCheck-properties" : {
+ "description" : "Dynamic PropertyDefinition for postCheck workflow(software-upgrade).",
"required" : true,
- "type" : "dt-postcheck-properties"
+ "type" : "dt-postCheck-properties"
}
}
}
@@ -255,7 +255,7 @@
}
}
},
- "precheck" : {
+ "preCheck" : {
"type" : "component-script-executor",
"interfaces" : {
"ComponentScriptExecutor" : {
@@ -269,7 +269,7 @@
"inputs" : {
"script-type" : "kotlin",
"script-class-reference" : "cba.pnf.swug.RestconfSoftwareUpgrade",
- "dynamic-properties" : "*precheck-properties"
+ "dynamic-properties" : "*preCheck-properties"
},
"outputs" : {
"response-data" : "",
@@ -290,7 +290,7 @@
}
}
},
- "downloadNeSw" : {
+ "downloadNESW" : {
"type" : "component-script-executor",
"interfaces" : {
"ComponentScriptExecutor" : {
@@ -304,7 +304,7 @@
"inputs" : {
"script-type" : "kotlin",
"script-class-reference" : "cba.pnf.swug.RestconfSoftwareUpgrade",
- "dynamic-properties" : "*downloadNeSw-properties"
+ "dynamic-properties" : "*downloadNESW-properties"
},
"outputs" : {
"response-data" : "",
@@ -341,7 +341,7 @@
}
}
},
- "activateNeSw" : {
+ "activateNESW" : {
"type" : "component-script-executor",
"interfaces" : {
"ComponentScriptExecutor" : {
@@ -355,7 +355,7 @@
"inputs" : {
"script-type" : "kotlin",
"script-class-reference" : "cba.pnf.swug.RestconfSoftwareUpgrade",
- "dynamic-properties" : "*activateNeSw-properties"
+ "dynamic-properties" : "*activateNESW-properties"
},
"outputs" : {
"response-data" : "",
@@ -384,7 +384,7 @@
}
}
},
- "postcheck" : {
+ "postCheck" : {
"type" : "component-script-executor",
"interfaces" : {
"ComponentScriptExecutor" : {
@@ -398,7 +398,7 @@
"inputs" : {
"script-type" : "kotlin",
"script-class-reference" : "cba.pnf.swug.RestconfSoftwareUpgrade",
- "dynamic-properties" : "*postcheck-properties"
+ "dynamic-properties" : "*postCheck-properties"
},
"outputs" : {
"response-data" : "",
diff --git a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/data_types.json b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/data_types.json
index e3d216c89..2a42ac091 100644
--- a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/data_types.json
+++ b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Definitions/data_types.json
@@ -19,8 +19,8 @@
},
"derived_from" : "tosca.datatypes.Dynamic"
},
- "dt-precheck-properties": {
- "description": "Dynamic DataType definition for the precheck workflow(upgrade-software).",
+ "dt-preCheck-properties": {
+ "description": "Dynamic DataType definition for the preCheck workflow(upgrade-software).",
"version": "1.0.0",
"properties": {
"pnf-id": {
@@ -32,8 +32,8 @@
},
"derived_from": "tosca.datatypes.Dynamic"
},
- "dt-downloadNeSw-properties": {
- "description": "Dynamic DataType definition for the downloadNeSw workflow(upgrade-software).",
+ "dt-downloadNESW-properties": {
+ "description": "Dynamic DataType definition for the downloadNESW workflow(upgrade-software).",
"version": "1.0.0",
"properties": {
"pnf-id": {
@@ -45,8 +45,8 @@
},
"derived_from": "tosca.datatypes.Dynamic"
},
- "dt-activateNeSw-properties": {
- "description": "Dynamic DataType definition for the activateNeSw workflow(upgrade-software).",
+ "dt-activateNESW-properties": {
+ "description": "Dynamic DataType definition for the activateNESW workflow(upgrade-software).",
"version": "1.0.0",
"properties": {
"pnf-id": {
@@ -58,8 +58,8 @@
},
"derived_from": "tosca.datatypes.Dynamic"
},
- "dt-postcheck-properties": {
- "description": "Dynamic DataType definition for the postcheck workflow(upgrade-software).",
+ "dt-postCheck-properties": {
+ "description": "Dynamic DataType definition for the postCheck workflow(upgrade-software).",
"version": "1.0.0",
"properties": {
"pnf-id": {
diff --git a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Scripts/kotlin/RestconfSoftwareUpgrade.kt b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Scripts/kotlin/RestconfSoftwareUpgrade.kt
index 07e804b95..9d00c60d8 100644
--- a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Scripts/kotlin/RestconfSoftwareUpgrade.kt
+++ b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Scripts/kotlin/RestconfSoftwareUpgrade.kt
@@ -60,10 +60,10 @@ class RestconfSoftwareUpgrade : AbstractScriptComponentFunction() {
restconfMountDevice(model.client, model.deviceId, mountPayload, mutableMapOf("Content-Type" to "application/json"))
when (model.action) {
- Action.PRE_CHECK -> processPrecheck(model)
- Action.DOWNLOAD_NE_SW -> processDownloadNeSw(model)
- Action.ACTIVATE_NE_SW -> processActivateNeSw(model)
- Action.POST_CHECK -> processPostcheck(model)
+ Action.PRE_CHECK -> processPreCheck(model)
+ Action.DOWNLOAD_NE_SW -> processDownloadNESW(model)
+ Action.ACTIVATE_NE_SW -> processActivateNESW(model)
+ Action.POST_CHECK -> processPostCheck(model)
Action.CANCEL -> processCancel(model)
}
@@ -74,7 +74,7 @@ class RestconfSoftwareUpgrade : AbstractScriptComponentFunction() {
}
}
- private suspend fun processPrecheck(model: SoftwareUpgradeModel) {
+ private suspend fun processPreCheck(model: SoftwareUpgradeModel) {
log.debug("In PNF SW upgrade : processPreCheck")
//Log the current configuration for the subtree
val payloadObject = getCurrentConfig(model)
@@ -82,8 +82,8 @@ class RestconfSoftwareUpgrade : AbstractScriptComponentFunction() {
log.info("PNF is Healthy!")
}
- private suspend fun processDownloadNeSw(model: SoftwareUpgradeModel) {
- log.debug("In PNF SW upgrade : processDownloadNeSw")
+ private suspend fun processDownloadNESW(model: SoftwareUpgradeModel) {
+ log.debug("In PNF SW upgrade : processDownloadNESW")
//Check if there is existing config for the targeted software version
var downloadConfigPayload: String
@@ -106,8 +106,8 @@ class RestconfSoftwareUpgrade : AbstractScriptComponentFunction() {
checkExecution(model)
}
- private suspend fun processActivateNeSw(model: SoftwareUpgradeModel) {
- log.debug("In PNF SW upgrade : processActivateNeSw")
+ private suspend fun processActivateNESW(model: SoftwareUpgradeModel) {
+ log.debug("In PNF SW upgrade : processActivateNESW")
//Check if the software is downloaded and ready to be activated
if (checkIfSwReadyToPerformAction(Action.DOWNLOAD_NE_SW, model)) {
var activateConfigPayload: String = contentFromResolvedArtifactNB("configure")
@@ -124,8 +124,8 @@ class RestconfSoftwareUpgrade : AbstractScriptComponentFunction() {
}
}
- private suspend fun processPostcheck(model: SoftwareUpgradeModel) {
- log.info("In PNF SW upgrade : processPostcheck")
+ private suspend fun processPostCheck(model: SoftwareUpgradeModel) {
+ log.info("In PNF SW upgrade : processPostCheck")
//Log the current configuration for the subtree
if (checkIfSwReadyToPerformAction(Action.POST_CHECK, model)) {
log.info("PNF is healthy post activation!")
@@ -175,10 +175,10 @@ class RestconfSoftwareUpgrade : AbstractScriptComponentFunction() {
}
enum class Action(val actionName: String, val completionStatus: String) {
- PRE_CHECK("precheck", "INITIALIZED"),
- DOWNLOAD_NE_SW("downloadNeSw", "DOWNLOAD_COMPLETED"),
- ACTIVATE_NE_SW("activateNeSw", "ACTIVATION_COMPLETED"),
- POST_CHECK("postcheck", "ACTIVATION_COMPLETED"),
+ PRE_CHECK("preCheck", "INITIALIZED"),
+ DOWNLOAD_NE_SW("downloadNESW", "DOWNLOAD_COMPLETED"),
+ ACTIVATE_NE_SW("activateNESW", "ACTIVATION_COMPLETED"),
+ POST_CHECK("postCheck", "ACTIVATION_COMPLETED"),
CANCEL("cancel", "CANCELLED")
;
companion object{
diff --git a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Tests/uat.yaml b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Tests/uat.yaml
index 79328e697..7136b1b0f 100644
--- a/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Tests/uat.yaml
+++ b/components/model-catalog/blueprint-model/uat-blueprints/PNF_CDS_RESTCONF/Tests/uat.yaml
@@ -56,21 +56,21 @@ processes:
errorMessage: null
eventType: EVENT_COMPONENT_EXECUTED
message: success
- - name: precheck
+ - name: preCheck
request:
commonHeader: &swugCommonHeader
originatorId: sdnc
requestId: "123456-1000"
subRequestId: sub-123456-1000
- actionIdentifiers: &precheck-ai
+ actionIdentifiers: &preCheck-ai
blueprintName: PNF_CDS_RESTCONF
blueprintVersion: "1.0.0"
- actionName: precheck
+ actionName: preCheck
mode: sync
payload:
- precheck-request:
+ preCheck-request:
resolution-key: &resKey "RES-KEY 61"
- precheck-properties: &actionProps
+ preCheck-properties: &actionProps
service-instance-id: siid_1234
pnf-id: &pnfId pnf-id-2019-07-12
target-software-version: "2.0.2"
@@ -78,26 +78,26 @@ processes:
pnf-customization-uuid: pnf-customization-uuid
expectedResponse:
commonHeader: *swugCommonHeader
- actionIdentifiers: *precheck-ai
+ actionIdentifiers: *preCheck-ai
status:
code: 200
eventType: EVENT_COMPONENT_EXECUTED
errorMessage: null
message: success
payload:
- precheck-response: {}
- - name: downloadNeSw
+ preCheck-response: {}
+ - name: downloadNESW
request:
commonHeader: *swugCommonHeader
actionIdentifiers: &download-ai
blueprintName: PNF_CDS_RESTCONF
blueprintVersion: "1.0.0"
- actionName: downloadNeSw
+ actionName: downloadNESW
mode: sync
payload:
- downloadNeSw-request:
+ downloadNESW-request:
resolution-key: *resKey
- downloadNeSw-properties: *actionProps
+ downloadNESW-properties: *actionProps
expectedResponse:
commonHeader: *swugCommonHeader
actionIdentifiers: *download-ai
@@ -107,19 +107,19 @@ processes:
errorMessage: null
message: success
payload:
- downloadNeSw-response: {}
- - name: activateNeSw
+ downloadNESW-response: {}
+ - name: activateNESW
request:
commonHeader: *swugCommonHeader
actionIdentifiers: &activate-ai
blueprintName: PNF_CDS_RESTCONF
blueprintVersion: "1.0.0"
- actionName: activateNeSw
+ actionName: activateNESW
mode: sync
payload:
- activateNeSw-request:
+ activateNESW-request:
resolution-key: *resKey
- activateNeSw-properties: *actionProps
+ activateNESW-properties: *actionProps
expectedResponse:
commonHeader: *swugCommonHeader
actionIdentifiers: *activate-ai
@@ -129,29 +129,29 @@ processes:
errorMessage: null
message: success
payload:
- activateNeSw-response: {}
- - name: postcheck
+ activateNESW-response: {}
+ - name: postCheck
request:
commonHeader: *swugCommonHeader
- actionIdentifiers: &postcheck-ai
+ actionIdentifiers: &postCheck-ai
blueprintName: PNF_CDS_RESTCONF
blueprintVersion: "1.0.0"
- actionName: postcheck
+ actionName: postCheck
mode: sync
payload:
- postcheck-request:
+ postCheck-request:
resolution-key: *resKey
- postcheck-properties: *actionProps
+ postCheck-properties: *actionProps
expectedResponse:
commonHeader: *swugCommonHeader
- actionIdentifiers: *postcheck-ai
+ actionIdentifiers: *postCheck-ai
status:
code: 200
eventType: EVENT_COMPONENT_EXECUTED
errorMessage: null
message: success
payload:
- postcheck-response: {}
+ postCheck-response: {}
external-services:
- selector: aai-data
expectations: