summaryrefslogtreecommitdiffstats
path: root/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org
diff options
context:
space:
mode:
authorZhuoyao Huang <10112215@zte.com.cn>2018-12-12 16:50:46 +0800
committerZhuoyao Huang <10112215@zte.com.cn>2018-12-15 09:59:12 +0800
commit4f4a600b69cffc75f944dd508ceb77c3b24854cd (patch)
tree328a23cb18dc7a7e23d4d5e37ead1b6b6f58217c /bpmn/so-bpmn-infrastructure-common/src/main/groovy/org
parentd9415dc1b8fe2c162568f5bf9ab50f1a1196d926 (diff)
Bug fix for getInstnaceId
CreateSDNCNetworkResource.afterCreateSDNCCall can't get instance id from getInstnaceId for modelName default case is missing Issue-ID: SO-1331 Change-Id: Ia5eb03131a3137e5eede83a97d5b464e66bd2055 Signed-off-by: Zhuoyao Huang <10112215@zte.com.cn>
Diffstat (limited to 'bpmn/so-bpmn-infrastructure-common/src/main/groovy/org')
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSDNCNetworkResource.groovy14
1 files changed, 7 insertions, 7 deletions
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSDNCNetworkResource.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSDNCNetworkResource.groovy
index a505f3ff5e..b2c278b64c 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSDNCNetworkResource.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/CreateSDNCNetworkResource.groovy
@@ -538,8 +538,8 @@ public class CreateSDNCNetworkResource extends AbstractServiceTaskProcessor {
}
private def getInstnaceId(DelegateExecution execution) {
- def responce = new XmlSlurper().parseText(execution.getVariable("CRENWKI_createSDNCResponse"))
- def data = responce.toString()
+ def response = new XmlSlurper().parseText(execution.getVariable("CRENWKI_createSDNCResponse"))
+ def data = response.toString()
data = data.substring(data.indexOf("<"))
def resp = new XmlSlurper().parseText(data)
@@ -548,11 +548,6 @@ public class CreateSDNCNetworkResource extends AbstractServiceTaskProcessor {
def val = ""
switch (modelName) {
- case ~/[\w\s\W]*SOTNConnectivity[\w\s\W]*/ :
- case ~/[\w\s\W]*SDWANConnectivity[\w\s\W]*/ :
- val = resp."network-response-information"."instance-id"
- break
-
case ~/[\w\s\W]*deviceVF[\w\s\W]*/ :
case ~/[\w\s\W]*SiteWANVF[\w\s\W]*/ :
case ~/[\w\s\W]*Site[\w\s\W]*/:
@@ -563,6 +558,11 @@ public class CreateSDNCNetworkResource extends AbstractServiceTaskProcessor {
case ~/[\w\s\W]*sotnvpnattachment[\w\s\W]*/:
val = resp."connection-attachment-response-information"."instance-id"
break
+
+ // for SDWANConnectivity and SOTNConnectivity and default:
+ default:
+ val = resp."network-response-information"."instance-id"
+ break
}
return val.toString()