summaryrefslogtreecommitdiffstats
path: root/platform-logic/generic-resource-api/src/main/xml
diff options
context:
space:
mode:
authorCheung, Pat (kc1472) <kc1472@att.com>2019-09-04 22:06:21 +0000
committerCheung, Pat (kc1472) <kc1472@att.com>2019-09-04 22:06:21 +0000
commitedfd51b6ac224d8d4eef723f109c78a532684a74 (patch)
tree20f15f4d81f060e1d48f348994067cf104578973 /platform-logic/generic-resource-api/src/main/xml
parent2577f3ce2a1989c2e6f6dba48cc3c21dea6696fa (diff)
generic-resource-api DG enhancement
Add vnf and vf-module async and concurrency support Issue-ID: SDNC-854 Signed-off-by: Cheung, Pat (kc1472) <kc1472@att.com> Change-Id: I2d1ebecca6661ef84d01994a77f5ec2f57c81497 Former-commit-id: 49752d7a66e8edf73e94fd2f7c6191dba1d2d2fc
Diffstat (limited to 'platform-logic/generic-resource-api/src/main/xml')
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-assign.xml141
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-mdsal-put.xml75
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-assign.xml196
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-mdsal-put.xml67
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_send-so-response.xml44
-rwxr-xr-xplatform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-assign.xml967
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-async.xml28
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation.xml9
-rwxr-xr-xplatform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-assign.xml726
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-async.xml28
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation.xml9
11 files changed, 1523 insertions, 767 deletions
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-assign.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-assign.xml
index de88ad7d..d2bb3a0c 100644
--- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-assign.xml
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-assign.xml
@@ -245,75 +245,13 @@ ss.capability.execution-order
<outcome value='failure'>
<block atomic='true'>
<set>
- <parameter name='vf.vf-module-id'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`' />
- <parameter name='vf.vf-module-data.sdnc-request-header.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.sdnc-request-header.`' />
- <parameter name='vf.vf-module-data.request-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.request-information.`' />
- <parameter name='vf.vf-module-data.service-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.service-information.`' />
- <parameter name='vf.vf-module-data.vnf-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vnf-information.`' />
- <parameter name='vf.vf-module-data.vf-module-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-information.`' />
- <parameter name='vf.vf-module-data.vf-module-topology.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.`' />
- <parameter name='vf.vf-module-data.vf-module-level-oper-status.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.vf-module-input-parameters.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.vf-module-input-parameters.`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.request-version'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.request-version`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.vf-module-name'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.vf-module-name`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.tenant'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.tenant`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.aic-cloud-region'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.aic-cloud-region`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.aic-clli'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.aic-clli`' />
+ <parameter name='error-message' value="`'Encountered error from ' + $ss.capability-dg + ' with error: ' + $error-message`" />
</set>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$prop.restapi.ss-vfmodule-assignments`"/>
- <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
- <parameter name="target" value="{service-instance-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.service-information.service-instance-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$tmp.ss-vfmodule-url`"/>
- <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
- <parameter name="target" value="{vnf-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vnf-information.vnf-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$tmp.ss-vfmodule-url`"/>
- <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
- <parameter name="target" value="{vf-module-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
- <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + $prop.restapi.ss.vfmodule.templatefile`" />
- <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ss-vfmodule-url`' />
- <parameter name='restapiUser' value='`$prop.controller.user`' />
- <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
- <parameter name='format' value='json' />
- <parameter name='httpMethod' value='PUT' />
- <parameter name="responsePrefix" value="mdsal-ss-vfmodule" />
- <outcome value='failure'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vf-module assignments during assign in MD-SAL" />
- </set>
- </outcome>
- <outcome value='not-found'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vf-module assignments during assign in MD-SAL" />
- </set>
- </outcome>
- </execute>
+ <call module='GENERIC-RESOURCE-API' rpc='self-serve-vf-module-mdsal-put' mode='sync' ></call>
<return status='failure'>
+ <parameter name='ack-final' value='Y'/>
<parameter name='error-code' value='500' />
- <parameter name='error-message' value="`'Encountered error from capability: '+ $ss.capability-dg + ', with error: '+ $error-message`" />
+ <parameter name='error-message' value="`$error-message`" />
</return>
</block>
</outcome>
@@ -330,75 +268,13 @@ ss.capability.execution-order
<outcome value='failure'>
<block atomic='true'>
<set>
- <parameter name='vf.vf-module-id'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`' />
- <parameter name='vf.vf-module-data.sdnc-request-header.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.sdnc-request-header.`' />
- <parameter name='vf.vf-module-data.request-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.request-information.`' />
- <parameter name='vf.vf-module-data.service-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.service-information.`' />
- <parameter name='vf.vf-module-data.vnf-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vnf-information.`' />
- <parameter name='vf.vf-module-data.vf-module-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-information.`' />
- <parameter name='vf.vf-module-data.vf-module-topology.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.`' />
- <parameter name='vf.vf-module-data.vf-module-level-oper-status.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.vf-module-input-parameters.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.vf-module-input-parameters.`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.request-version'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.request-version`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.vf-module-name'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.vf-module-name`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.tenant'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.tenant`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.aic-cloud-region'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.aic-cloud-region`' />
- <parameter name='vf.vf-module-data.vf-module-request-input.aic-clli'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.aic-clli`' />
+ <parameter name='error-message' value="`'Encountered error from ' + $ss.capability-dg + ' with error: ' + $error-message`" />
</set>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$prop.restapi.ss-vfmodule-assignments`"/>
- <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
- <parameter name="target" value="{service-instance-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.service-information.service-instance-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$tmp.ss-vfmodule-url`"/>
- <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
- <parameter name="target" value="{vnf-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vnf-information.vnf-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$tmp.ss-vfmodule-url`"/>
- <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
- <parameter name="target" value="{vf-module-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
- <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + $prop.restapi.ss.vfmodule.templatefile`" />
- <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ss-vfmodule-url`' />
- <parameter name='restapiUser' value='`$prop.controller.user`' />
- <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
- <parameter name='format' value='json' />
- <parameter name='httpMethod' value='PUT' />
- <parameter name="responsePrefix" value="mdsal-ss-vfmodule" />
- <outcome value='failure'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vf-module assignments during assign in MD-SAL" />
- </set>
- </outcome>
- <outcome value='not-found'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vf-module assignments during assign in MD-SAL" />
- </set>
- </outcome>
- </execute>
+ <call module='GENERIC-RESOURCE-API' rpc='self-serve-vf-module-mdsal-put' mode='sync' ></call>
<return status='failure'>
+ <parameter name='ack-final' value='Y'/>
<parameter name='error-code' value='500' />
- <parameter name='error-message' value="`'Encountered error from capability: '+ $ss.capability-dg + ', with error: '+ $error-message`" />
+ <parameter name='error-message' value="`$error-message`" />
</return>
</block>
</outcome>
@@ -417,6 +293,7 @@ ss.capability.execution-order
</switch>
</for>
</for>
+ <call module='GENERIC-RESOURCE-API' rpc='self-serve-vf-module-mdsal-put' mode='sync' ></call>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/ss-vf-assign.log' />
</execute>
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-mdsal-put.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-mdsal-put.xml
new file mode 100644
index 00000000..76b60872
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vf-module-mdsal-put.xml
@@ -0,0 +1,75 @@
+<service-logic
+ xmlns='http://www.onap.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ <method rpc='self-serve-vf-module-mdsal-put' mode='sync'>
+ <block atomic='true'>
+ <set>
+ <parameter name='vf.vf-module-id'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`' />
+ <parameter name='vf.vf-module-data.sdnc-request-header.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.sdnc-request-header.`' />
+ <parameter name='vf.vf-module-data.request-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.request-information.`' />
+ <parameter name='vf.vf-module-data.service-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.service-information.`' />
+ <parameter name='vf.vf-module-data.vnf-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vnf-information.`' />
+ <parameter name='vf.vf-module-data.vf-module-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-information.`' />
+ <parameter name='vf.vf-module-data.vf-module-topology.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.`' />
+ <parameter name='vf.vf-module-data.vf-module-level-oper-status.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.`' />
+ <parameter name='vf.vf-module-data.vf-module-request-input.vf-module-input-parameters.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.vf-module-input-parameters.`' />
+ <parameter name='vf.vf-module-data.vf-module-request-input.request-version'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.request-version`' />
+ <parameter name='vf.vf-module-data.vf-module-request-input.vf-module-name'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.vf-module-name`' />
+ <parameter name='vf.vf-module-data.vf-module-request-input.tenant'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.tenant`' />
+ <parameter name='vf.vf-module-data.vf-module-request-input.aic-cloud-region'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.aic-cloud-region`' />
+ <parameter name='vf.vf-module-data.vf-module-request-input.aic-clli'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.aic-clli`' />
+ </set>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$prop.restapi.ss-vfmodule-assignments`"/>
+ <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
+ <parameter name="target" value="{service-instance-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.service-information.service-instance-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$tmp.ss-vfmodule-url`"/>
+ <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
+ <parameter name="target" value="{vnf-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vnf-information.vnf-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$tmp.ss-vfmodule-url`"/>
+ <parameter name="outputPath" value="tmp.ss-vfmodule-url"/>
+ <parameter name="target" value="{vf-module-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + $prop.restapi.ss.vfmodule.templatefile`" />
+ <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ss-vfmodule-url`' />
+ <parameter name='restapiUser' value='`$prop.controller.user`' />
+ <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
+ <parameter name='format' value='json' />
+ <parameter name='httpMethod' value='PUT' />
+ <parameter name="responsePrefix" value="mdsal-ss-vfmodule" />
+ <outcome value='failure'>
+ <set>
+ <parameter name="error-message" value="`'Failed to persist self-serve vf-module assignments during assign in MD-SAL. ' + $error-message`" />
+ </set>
+ </outcome>
+ <outcome value='not-found'>
+ <set>
+ <parameter name="error-message" value="`'Failed to persist self-serve vf-module assignments during assign in MD-SAL. ' + $error-message`" />
+ </set>
+ </outcome>
+ </execute>
+ </block>
+ </method>
+</service-logic> \ No newline at end of file
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-assign.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-assign.xml
index c8b52b29..96db3efe 100644
--- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-assign.xml
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-assign.xml
@@ -223,154 +223,62 @@ ss.capability.execution-order[]
</set>
<switch test='`$ss.capability-name == $tmp.param.capability-name`'>
<outcome value='true'>
- <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$pidx].resource-resolution-data.status`'>
- <outcome value='PENDING'>
- <call module='GENERIC-RESOURCE-API' rpc='`$ss.capability-dg`' mode='sync' >
- <outcome value='failure'>
- <block atomic='true'>
- <set>
- <parameter name='vf.vnf-id'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-id`' />
- <parameter name='vf.vnf-data.sdnc-request-header.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.sdnc-request-header.`' />
- <parameter name='vf.vnf-data.request-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.request-information.`' />
- <parameter name='vf.vnf-data.service-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.`' />
- <parameter name='vf.vnf-data.vnf-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-information.`' />
- <parameter name='vf.vnf-data.vnf-topology.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.`' />
- <parameter name='vf.vnf-data.vnf-level-oper-status.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.`' />
- <parameter name='vf.vnf-data.vnf-request-input.vnf-input-parameters.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.`' />
- <parameter name='vf.vnf-data.vnf-request-input.request-version'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.request-version`' />
- <parameter name='vf.vnf-data.vnf-request-input.vnf-name'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-name`' />
- <parameter name='vf.vnf-data.vnf-request-input.tenant'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.tenant`' />
- <parameter name='vf.vnf-data.vnf-request-input.aic-cloud-region'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.aic-cloud-region`' />
- <parameter name='vf.vnf-data.vnf-request-input.aic-clli'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.aic-clli`' />
- </set>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$prop.restapi.ss-vnf-assignments`"/>
- <parameter name="outputPath" value="tmp.ss-vnf-url"/>
- <parameter name="target" value="{service-instance-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.service-instance-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$tmp.ss-vnf-url`"/>
- <parameter name="outputPath" value="tmp.ss-vnf-url"/>
- <parameter name="target" value="{vnf-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
- <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + $prop.restapi.ss.vnf.templatefile`" />
- <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ss-vnf-url`' />
- <parameter name='restapiUser' value='`$prop.controller.user`' />
- <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
- <parameter name='format' value='json' />
- <parameter name='httpMethod' value='PUT' />
- <parameter name="responsePrefix" value="mdsal-ss-vnf" />
- <outcome value='failure'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vnf assignments during assign in MD-SAL" />
- </set>
- </outcome>
- <outcome value='not-found'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vnf assignments during assign in MD-SAL" />
- </set>
- </outcome>
- </execute>
- <return status='failure'>
- <parameter name='error-code' value='500' />
- <parameter name='error-message' value="`'Encountered error from capability: '+ $ss.capability-dg + ', with error: '+ $error-message`" />
- </return>
- </block>
- </outcome>
- </call>
- </outcome>
- <outcome value='FAILED'>
- <call module='GENERIC-RESOURCE-API' rpc='`$ss.capability-dg`' mode='sync' >
- <outcome value='failure'>
- <block atomic='true'>
- <set>
- <parameter name='vf.vnf-id'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-id`' />
- <parameter name='vf.vnf-data.sdnc-request-header.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.sdnc-request-header.`' />
- <parameter name='vf.vnf-data.request-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.request-information.`' />
- <parameter name='vf.vnf-data.service-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.`' />
- <parameter name='vf.vnf-data.vnf-information.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-information.`' />
- <parameter name='vf.vnf-data.vnf-topology.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.`' />
- <parameter name='vf.vnf-data.vnf-level-oper-status.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.`' />
- <parameter name='vf.vnf-data.vnf-request-input.vnf-input-parameters.'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.`' />
- <parameter name='vf.vnf-data.vnf-request-input.request-version'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.request-version`' />
- <parameter name='vf.vnf-data.vnf-request-input.vnf-name'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-name`' />
- <parameter name='vf.vnf-data.vnf-request-input.tenant'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.tenant`' />
- <parameter name='vf.vnf-data.vnf-request-input.aic-cloud-region'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.aic-cloud-region`' />
- <parameter name='vf.vnf-data.vnf-request-input.aic-clli'
- value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.aic-clli`' />
- </set>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$prop.restapi.ss-vnf-assignments`"/>
- <parameter name="outputPath" value="tmp.ss-vnf-url"/>
- <parameter name="target" value="{service-instance-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.service-instance-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
- <parameter name="source" value="`$tmp.ss-vnf-url`"/>
- <parameter name="outputPath" value="tmp.ss-vnf-url"/>
- <parameter name="target" value="{vnf-id}"/>
- <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-id`"/>
- </execute>
- <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
- <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + $prop.restapi.ss.vnf.templatefile`" />
- <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ss-vnf-url`' />
- <parameter name='restapiUser' value='`$prop.controller.user`' />
- <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
- <parameter name='format' value='json' />
- <parameter name='httpMethod' value='PUT' />
- <parameter name="responsePrefix" value="mdsal-ss-vnf" />
- <outcome value='failure'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vnf assignments during assign in MD-SAL" />
- </set>
- </outcome>
- <outcome value='not-found'>
- <set>
- <parameter name="error-message" value="Failed to persist self-serve vnf assignments during assign in MD-SAL" />
- </set>
- </outcome>
- </execute>
- <return status='failure'>
- <parameter name='error-code' value='500' />
- <parameter name='error-message' value="`'Encountered error from capability: '+ $ss.capability-dg + ', with error: '+ $error-message`" />
- </return>
- </block>
- </outcome>
- </call>
- </outcome>
- </switch>
+ <block atomic='true'>
+ <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$pidx].resource-resolution-data.status`'>
+ <outcome value='PENDING'>
+ <call module='GENERIC-RESOURCE-API' rpc='`$ss.capability-dg`' mode='sync' >
+ <outcome value='failure'>
+ <block atomic='true'>
+ <set>
+ <parameter name='error-message' value="`'Encountered error from ' + $ss.capability-dg + ' with error: ' + $error-message`" />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='self-serve-vnf-mdsal-put' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name='error-code' value='500' />
+ <parameter name='error-message' value="`$error-message`" />
+ </return>
+ </block>
+ </outcome>
+ <outcome value='success'>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder">
+ <parameter name="logger" value="message-log"/>
+ <parameter name="field1" value="`'EXECUTION DONE: ' + $ss.capability-dg`"/>
+ </record>
+ </outcome>
+ </call>
+ </outcome>
+ <outcome value='FAILED'>
+ <call module='GENERIC-RESOURCE-API' rpc='`$ss.capability-dg`' mode='sync' >
+ <outcome value='failure'>
+ <block atomic='true'>
+ <set>
+ <parameter name='error-message' value="`'Encountered error from ' + $ss.capability-dg + ' with error: ' + $error-message`" />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='self-serve-vnf-mdsal-put' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name='error-code' value='500' />
+ <parameter name='error-message' value="`$error-message`" />
+ </return>
+ </block>
+ </outcome>
+ <outcome value='success'>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder">
+ <parameter name="logger" value="message-log"/>
+ <parameter name="field1" value="`'EXECUTION DONE: ' + $ss.capability-dg`"/>
+ </record>
+ </outcome>
+ </call>
+ </outcome>
+ </switch>
+ <break/>
+ </block>
</outcome>
</switch>
</for>
</for>
+ <call module='GENERIC-RESOURCE-API' rpc='self-serve-vnf-mdsal-put' mode='sync' ></call>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/ss-vnf-assign.log' />
</execute>
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-mdsal-put.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-mdsal-put.xml
new file mode 100644
index 00000000..a35b4c1b
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-vnf-mdsal-put.xml
@@ -0,0 +1,67 @@
+<service-logic
+ xmlns='http://www.onap.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ <method rpc='self-serve-vnf-mdsal-put' mode='sync'>
+ <block atomic='true'>
+ <set>
+ <parameter name='vf.vnf-id'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-id`' />
+ <parameter name='vf.vnf-data.sdnc-request-header.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.sdnc-request-header.`' />
+ <parameter name='vf.vnf-data.request-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.request-information.`' />
+ <parameter name='vf.vnf-data.service-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.`' />
+ <parameter name='vf.vnf-data.vnf-information.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-information.`' />
+ <parameter name='vf.vnf-data.vnf-topology.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.`' />
+ <parameter name='vf.vnf-data.vnf-level-oper-status.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.`' />
+ <parameter name='vf.vnf-data.vnf-request-input.vnf-input-parameters.'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.`' />
+ <parameter name='vf.vnf-data.vnf-request-input.request-version'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.request-version`' />
+ <parameter name='vf.vnf-data.vnf-request-input.vnf-name'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-name`' />
+ <parameter name='vf.vnf-data.vnf-request-input.tenant'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.tenant`' />
+ <parameter name='vf.vnf-data.vnf-request-input.aic-cloud-region'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.aic-cloud-region`' />
+ <parameter name='vf.vnf-data.vnf-request-input.aic-clli'
+ value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.aic-clli`' />
+ </set>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$prop.restapi.ss-vnf-assignments`"/>
+ <parameter name="outputPath" value="tmp.ss-vnf-url"/>
+ <parameter name="target" value="{service-instance-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.service-instance-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$tmp.ss-vnf-url`"/>
+ <parameter name="outputPath" value="tmp.ss-vnf-url"/>
+ <parameter name="target" value="{vnf-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + $prop.restapi.ss.vnf.templatefile`" />
+ <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ss-vnf-url`' />
+ <parameter name='restapiUser' value='`$prop.controller.user`' />
+ <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
+ <parameter name='format' value='json' />
+ <parameter name='httpMethod' value='PUT' />
+ <parameter name="responsePrefix" value="mdsal-ss-vnf" />
+ <outcome value='failure'>
+ <set>
+ <parameter name="error-message" value="`'Failed to persist self-serve vnf assignments during assign in MD-SAL. ' + $error-message`" />
+ </set>
+ </outcome>
+ <outcome value='not-found'>
+ <set>
+ <parameter name="error-message" value="`'Failed to persist self-serve vnf assignments during assign in MD-SAL. ' + $error-message`" />
+ </set>
+ </outcome>
+ </execute>
+ </block>
+ </method>
+</service-logic> \ No newline at end of file
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_send-so-response.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_send-so-response.xml
new file mode 100644
index 00000000..bf4c2641
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_send-so-response.xml
@@ -0,0 +1,44 @@
+<service-logic
+ xmlns='http://www.onap.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ <method rpc='send-so-response' mode='sync'>
+ <block atomic="true">
+ <set>
+ <parameter name="so.response-message" value="`$error-message`" />
+ </set>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + 'so-response.json'`" />
+ <parameter name='restapiUrl' value="`$so.notification-url`" />
+ <parameter name='restapiUser' value='`$prop.so.user`' />
+ <parameter name='restapiPassword' value='`$prop.so.pwd`' />
+ <parameter name='format' value='json' />
+ <parameter name='httpMethod' value='POST' />
+ <parameter name="responsePrefix" value="soResponse-vnf-assign" />
+ <outcome value='failure'>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Error sending SO response. ' + $error-message`" />
+ </set>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </outcome>
+ <outcome value='not-found'>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Error sending SO response. ' + $error-message`" />
+ </set>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </outcome>
+ </execute>
+ </block>
+ </method>
+</service-logic> \ No newline at end of file
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-assign.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-assign.xml
index b7888ede..b9589a70 100755
--- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-assign.xml
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-assign.xml
@@ -1,12 +1,20 @@
<service-logic
xmlns='http://www.onap.org/sdnc/svclogic'
- xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='1-4-2-20181108R1'>
<method rpc='vf-module-topology-operation-assign' mode='sync'>
<block atomic="true">
<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >
<parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />
<parameter name='contextPrefix' value='prop' />
</execute>
+ <set>
+ <parameter name="so.ack-final-indicator" value="Y" />
+ <parameter name="so.response-code" value="500" />
+ <parameter name="so.notification-url" value="`$vf-module-topology-operation-input.sdnc-request-header.svc-notification-url`" />
+ <parameter name="so.svc-request-id" value="`$vf-module-topology-operation-input.sdnc-request-header.svc-request-id`" />
+ <parameter name="so.service-type" value="`$vf-module-topology-operation-input.service-information.subscription-service-type`" />
+ <parameter name="so.service-instance-id" value="`$vf-module-topology-operation-input.service-information.service-instance-id`" />
+ </set>
<switch test='`$vf-module-topology-operation-input.vf-module-request-input.cloud-owner`'>
<outcome value=''>
<block></block>
@@ -22,29 +30,53 @@
<block></block>
</outcome>
<outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="If svc-action is 'assign' then request-action must be 'CreateVfModuleInstance'" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="If svc-action is 'assign' then request-action must be 'CreateVfModuleInstance'" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
<get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
key='SELECT * from VF_MODULE_MODEL WHERE customization_uuid = $vf-module-topology-operation-input.vf-module-information.onap-model-information.model-customization-uuid'
pfx='db.vf-module-model'>
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error reading VF_MODULE_MODEL table" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error reading VF_MODULE_MODEL table" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='not-found'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No model found for VF module customization UUID ' + $vf-module-topology-operation-input.vf-module-information.onap-model-information.model-customization-uuid`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No model found for VF module customization UUID ' + $vf-module-topology-operation-input.vf-module-information.onap-model-information.model-customization-uuid`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</get-resource>
<set>
@@ -52,11 +84,19 @@
</set>
<switch test='`$service-data.vnfs.vnf_length`'>
<outcome value=''>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="There are no VNFs defined in MD-SAL" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="There are no VNFs defined in MD-SAL" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='Other'>
<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >
@@ -75,11 +115,19 @@
</switch>
<switch test='`$vnf-index`'>
<outcome value='-1'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unable to find VNF ID ' + $vf-module-topology-operation-input.vnf-information.vnf-id + ' in MD-SAL'`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Unable to find VNF ID ' + $vf-module-topology-operation-input.vnf-information.vnf-id + ' in MD-SAL'`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
<call module='GENERIC-RESOURCE-API' rpc='self-serve-vf-module-forking-logic' mode='sync' ></call>
@@ -88,11 +136,19 @@
<block atomic="true">
<call module='GENERIC-RESOURCE-API' rpc='self-serve-vf-module-assign' mode='sync' >
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Failed to create self-serve assignment for vf-module with vf-module-id=' + $vf-module-topology-operation-input.vf-module-information.vf-module-id + ' with error: ' + $error-message`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Failed to create self-serve assignment for vf-module with vf-module-id=' + $vf-module-topology-operation-input.vf-module-information.vf-module-id + ' with error: ' + $error-message`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</call>
<set>
@@ -101,11 +157,15 @@
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.last-rpc-action'
value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.last-action'
- value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />
+ value='`$vf-module-topology-operation-input.request-information.request-action`' />
</set>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/ss-vnfend.log' />
</execute>
+ <set>
+ <parameter name="so.response-code" value="200" />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
<return status='success'>
<parameter name="ack-final-indicator" value="Y" />
<parameter name="error-code" value="200" />
@@ -129,12 +189,20 @@
<for index='idx' start='0' end='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' >
<switch test='`$vf-module-topology-operation-input.vf-module-information.vf-module-id == $service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id`'>
<outcome value='true'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'VF module id ' + $service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'VF module id ' + $service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id
+ ' already exists, and status is ' + $service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.vf-module-level-oper-status.order-status`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
</for>
@@ -161,18 +229,34 @@
cloud-region.cloud-region-id = $vf-module-topology-operation-input.vf-module-request-input.aic-cloud-region"
pfx='aai.cloud-region' local-only='false' >
<outcome value='not-found'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Cloud region not found in AAI" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Cloud region not found in AAI" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error retrieving cloud region from AAI" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error retrieving cloud region from AAI. Is AAI down?" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</get-resource>
<for index='idx' start='0' end='`$aai.cloud-region.relationship-list.relationship_length`' >
@@ -195,11 +279,19 @@
</for>
<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.aic-clli`'>
<outcome value=''>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unable to find aic-clli in AAI for aic-cloud-region ' + $vf-module-topology-operation-input.vf-module-request-input.aic-cloud-region`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Unable to find aic-clli in AAI for aic-cloud-region ' + $vf-module-topology-operation-input.vf-module-request-input.aic-cloud-region`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
<switch test='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-invariant-uuid`'>
@@ -267,8 +359,18 @@
<call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-operation-assign-no-preload' mode='sync' >
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'></return>
+ <set>
+ <parameter name="error-message" value="`'from-preload flag is true but could not find preload information for VF module name ' + $vf-module-topology-operation-input.vf-module-request-input.vf-module-name`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</call>
@@ -288,20 +390,36 @@
<call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-operation-assign-no-preload' mode='sync' >
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'></return>
+ <set>
+ <parameter name="error-message" value="`'from-preload flag is true but could not find preload information for VF module name ' + $vf-module-topology-operation-input.vf-module-request-input.vf-module-name`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</call>
</outcome>
<outcome value='Other'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error retrieving preload-information" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</switch>
@@ -311,9 +429,14 @@
<block>
<call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-operation-assign-preload' mode='sync' >
<outcome value='failure'>
- <block atomic="true">
+ <block atomic='true'>
<call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'></return>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
</outcome>
</call>
@@ -364,15 +487,21 @@
<switch test='`$vnf-network-index`'>
<outcome value='-1'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="`'VNFC network role '
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-networks.vnfc-network-data[$vnfc-network-index].vnfc-network-role
+ ' is not found in VNF network list'
`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</switch>
@@ -431,28 +560,40 @@
<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-resource-assignments.vnf-networks.vnf-network[$vnf-network-index].subnets-data.subnet-data[$subnet-data-index].network-start-address`'>
<outcome value=''>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="`'SDNC subnet id '
+ $service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-resource-assignments.vnf-networks.vnf-network[$vnf-network-index].subnets-data.subnet-data[$subnet-data-index].sdnc-subnet-id
+ ' does not have network-start-address populated'`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='Other'>
<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-resource-assignments.vnf-networks.vnf-network[$vnf-network-index].subnets-data.subnet-data[$subnet-data-index].cidr-mask`'>
<outcome value=''>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="`'SDNC subnet id '
+ $service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-resource-assignments.vnf-networks.vnf-network[$vnf-network-index].subnets-data.subnet-data[$subnet-data-index].sdnc-subnet-id
+ ' does not have cidr-mask populated'`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='Other'>
@@ -494,14 +635,20 @@
<switch test='`$subnet-id`'>
<outcome value='-1'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="`'Not able to find VNF network subnet that contains address '
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-networks.vnfc-network-data[$vnfc-network-index].vnfc-subnet[$subnet-role-index].vnfc-ip-assignments[$address-family-index].vnfc-subnet-ip[0].vnfc-ip-address
`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</switch>
@@ -533,13 +680,19 @@
and network_role = $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-networks.vm-network[$network-role-index].network-role'
pfx='db.vnf-related-network-role[]'>
<outcome value='failure'>
- <block>
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <block atomic='true'>
+ <set>
<parameter name="error-message" value="Error reading VFC_RELATED_NETWORK_ROLE table" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='success'>
@@ -576,14 +729,20 @@
</for>
<switch test='`$found-related-network`'>
<outcome value='false'>
- <block>
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <block atomic='true'>
+ <set>
<parameter name="error-message" value="`'Unable to find related network '
+ $db.vnf-related-network-role[$db-related-network-index].related-network-role + ' in vnf-networks'`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</switch>
@@ -662,22 +821,25 @@
<parameter name="automated-assignment" value="`$automated-assignment`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vf-module in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="`'No vf-module found in AAI for vf module ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`" />
- </return>
+ </set>
</block>
</outcome>
</update>
@@ -722,22 +884,34 @@
<parameter name="prov-status" value="`PREPROV`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error saving vnfc to AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error saving vnfc to AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -757,22 +931,34 @@
<parameter name="prov-status" value="`PREPROV`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error saving vnfc to AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error saving vnfc to AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -797,22 +983,34 @@
$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-id`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vnfc relationships in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating vnfc relationships" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -829,22 +1027,34 @@
<parameter name="port-id" value="0" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error creating cp object in AAI" />
- </return>
+ <set>
+ <parameter name="error-message" value="Error saving cp object to AAI" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error creating cp object in AAI" />
- </return>
+ <set>
+ <parameter name="error-message" value="Error saving cp object to AAI" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -875,12 +1085,18 @@
<parameter name="is-floating" value="false" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error creating l3-interface-ipv4-address-list object in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -902,22 +1118,34 @@
$tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-networks.vnfc-network-data[$network-role-index].vnfc-subnet[$subnet-role-index].vnfc-ip-assignments[$address-family-index].subnet-id`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating l3-interface-ipv4-address-list relationships in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating l3-interface-ipv4-address-list relationships" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -935,12 +1163,18 @@
<parameter name="is-floating" value="false" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error creating l3-interface-ipv6-address-list object in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -962,22 +1196,34 @@
$tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-networks.vnfc-network-data[$network-role-index].vnfc-subnet[$subnet-role-index].vnfc-ip-assignments[$address-family-index].subnet-id`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating l3-interface-ipv6-address-list relationships in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating l3-interface-ipv6-address-list relationships" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1003,22 +1249,34 @@
$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-resource-assignments.vnf-networks.vnf-network[$vnf-network-index].network-id`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating cp relationship to l3-network in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating cp relationship to l3-network" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1045,22 +1303,34 @@
$tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-networks.vm-network[$network-role-index].related-networks.related-network[$related-network-index].vlan-tags.vlan-interface`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating cp relationship to l3-network and vlan-tag in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating cp relationship to l3-network and vlan-tag" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1085,23 +1355,35 @@
$tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-networks.vm-network[$network-role-index].network-id`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vf-module relationships in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="`'No l3-network found in AAI for network ID '
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-networks.vm-network[$network-role-index].network-id`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1120,22 +1402,34 @@
<parameter name="is-floating" value="false" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error saving vip-ipv4-address-list in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error saving vip-ipv4-address-list" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1162,22 +1456,34 @@
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-name`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vip-ipv4-address-list relationships in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating vip-ipv4-address-list relationships" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1199,22 +1505,34 @@
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-networks.vnfc-network-data[$vnfc-network-role-index].connection-point.connection-point-id`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vip-ipv4-address-list relationship to cp in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating vip-ipv4-address-list relationship to cp" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1237,22 +1555,34 @@
<parameter name="is-floating" value="false" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error saving vip-ipv6-address-list in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error saving vip-ipv6-address-list" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1279,22 +1609,34 @@
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-name`" />
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vip-ipv6-address-list relationships in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating vip-ipv6-address-list relationships" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1316,20 +1658,34 @@
+ $tmp.vf-module-topology.vf-module-assignments.vms.vm[$vm-type-index].vm-names.vnfc-names[$vnfc-index].vnfc-networks.vnfc-network-data[$vnfc-network-role-index].connection-point.connection-point-id`" />
<outcome value='failure'>
<block atomic="true">
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Error updating vip-ipv4-address-list relationship to cp in AAI" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
<outcome value='not-found'>
<block atomic="true">
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
+ <set>
<parameter name="error-message" value="Not-found error updating vip-ipv4-address-list relationship to cp" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</save>
@@ -1347,11 +1703,18 @@
<call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-vlan-tagging-assign' mode='sync' >
<outcome value='failure'>
<block atomic="true">
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/bgb-vlantaggingfailure.log' />
</execute>
- <return status='failure'></return>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
</block>
</outcome>
</call>
@@ -1408,7 +1771,6 @@ key="INSERT INTO VIPR_CONFIGURATION (vnf_id, vnf_name, ecomp_service_instance_id
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-request-input.'
value='$vf-module-topology-operation-input.vf-module-request-input.' />
</set>
- <call module='GENERIC-RESOURCE-API' rpc='gw-vfmodule-update' mode='sync' ></call>
<set>
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.order-status'
value='PendingCreate' />
@@ -1417,9 +1779,76 @@ key="INSERT INTO VIPR_CONFIGURATION (vnf_id, vnf_name, ecomp_service_instance_id
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-level-oper-status.last-action'
value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />
</set>
+ <set>
+ <parameter name='vf-module-data.'
+ value='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.' />
+ </set>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$prop.restapi.vf-module`"/>
+ <parameter name="outputPath" value="tmp.part"/>
+ <parameter name="target" value="{service-instance-id}"/>
+ <parameter name="replacement" value="`$service-data.service-topology.service-topology-identifier.service-instance-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$tmp.part`"/>
+ <parameter name="outputPath" value="tmp.part"/>
+ <parameter name="target" value="{vnf-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$tmp.part`"/>
+ <parameter name="outputPath" value="tmp.vf-module.url"/>
+ <parameter name="target" value="{vf-module-id}"/>
+ <parameter name="replacement" value="`$vf-module-topology-operation-input.vf-module-information.vf-module-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + 'vf-module-assign.json'`" />
+ <parameter name='restapiUrl' value="`$prop.controller.url + $tmp.vf-module.url`" />
+ <parameter name='restapiUser' value='`$prop.controller.user`' />
+ <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
+ <parameter name='format' value='json' />
+ <parameter name='httpMethod' value='PUT' />
+ <parameter name="responsePrefix" value="vf-module-assign" />
+ <outcome value='failure'>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error doing PUT of vf-module" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
+ </outcome>
+ <outcome value='not-found'>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error doing PUT of vf-module" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-assign-rollback' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
+ </outcome>
+ </execute>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/bgb-vfmodule.log' />
</execute>
+ <set>
+ <parameter name="so.response-code" value="200" />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
<return status='success'>
<parameter name="ack-final-indicator" value="Y" />
<parameter name="error-code" value="200" />
@@ -1430,4 +1859,4 @@ key="INSERT INTO VIPR_CONFIGURATION (vnf_id, vnf_name, ecomp_service_instance_id
</switch>
</block>
</method>
-</service-logic>
+</service-logic> \ No newline at end of file
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-async.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-async.xml
new file mode 100644
index 00000000..4c89d83b
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation-async.xml
@@ -0,0 +1,28 @@
+<service-logic
+ xmlns='http://www.onap.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ <method rpc='vf-module-topology-operation-async' mode='sync'>
+ <block atomic="true">
+ <set>
+ <parameter name='skip-mdsal-update' value='Y' />
+ </set>
+ <switch test='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`'>
+ <outcome value='assign'>
+ <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-operation-assign' mode='sync' ></call>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$vnf-topology-operation-input.sdnc-request-header.svc-action + ' is not a valid svc-action'`" />
+ </return>
+ </outcome>
+ </switch>
+ <return status='success'>
+ <parameter name="ack-final" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </method>
+</service-logic> \ No newline at end of file
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation.xml
index 24863d44..dae4b9b9 100644
--- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation.xml
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vf-module-topology-operation.xml
@@ -6,7 +6,14 @@
<call module='GENERIC-RESOURCE-API' rpc='validate-vf-module-input' mode='sync' ></call>
<switch test='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`'>
<outcome value='assign'>
- <call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-operation-assign' mode='sync' ></call>
+ <block atomic="true">
+ <set>
+ <parameter name='skip-mdsal-update' value='Y' />
+ </set>
+ <set>
+ <parameter name='ack-final' value='N' />
+ </set>
+ </block>
</outcome>
<outcome value='unassign'>
<call module='GENERIC-RESOURCE-API' rpc='vf-module-topology-operation-unassign' mode='sync' ></call>
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-assign.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-assign.xml
index 1433b7b5..66341c30 100755
--- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-assign.xml
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-assign.xml
@@ -7,6 +7,14 @@
<parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />
<parameter name='contextPrefix' value='prop' />
</execute>
+ <set>
+ <parameter name="so.ack-final-indicator" value="Y" />
+ <parameter name="so.response-code" value="500" />
+ <parameter name="so.notification-url" value="`$vnf-topology-operation-input.sdnc-request-header.svc-notification-url`" />
+ <parameter name="so.svc-request-id" value="`$vnf-topology-operation-input.sdnc-request-header.svc-request-id`" />
+ <parameter name="so.service-type" value="`$vnf-topology-operation-input.service-information.subscription-service-type`" />
+ <parameter name="so.service-instance-id" value="`$vnf-topology-operation-input.service-information.service-instance-id`" />
+ </set>
<switch test='`$vnf-topology-operation-input.vnf-request-input.cloud-owner`'>
<outcome value=''>
<block></block>
@@ -22,29 +30,53 @@
<block></block>
</outcome>
<outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="If svc-action is 'assign' then request-action must be 'CreateVnfInstance'" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="If svc-action is 'assign' then request-action must be 'CreateVnfInstance'" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
<get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'
key='SELECT * from VF_MODEL WHERE customization_uuid = $vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid'
pfx='db.vf-model'>
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error reading VF_MODEL table" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error reading VF_MODEL table" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='not-found'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No model found for VNF customization UUID ' + $vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No model found for VNF customization UUID ' + $vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</get-resource>
<call module='GENERIC-RESOURCE-API' rpc='self-serve-vnf-forking-logic' mode='sync' ></call>
@@ -53,11 +85,19 @@
<block atomic="true">
<call module='GENERIC-RESOURCE-API' rpc='self-serve-vnf-assign' mode='sync' >
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Failed to create self-serve assignment for vnf with vnf-id=' + $vnf-topology-operation-input.vnf-information.vnf-id + ' with error: ' + $error-message`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Failed to create self-serve assignment for vnf with vnf-id=' + $vnf-topology-operation-input.vnf-information.vnf-id + ' with error: ' + $error-message`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</call>
<set>
@@ -68,6 +108,10 @@
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/ss-vnfend.log' />
</execute>
+ <set>
+ <parameter name="so.response-code" value="200" />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
<return status='success'>
<parameter name="ack-final-indicator" value="Y" />
<parameter name="error-code" value="200" />
@@ -84,19 +128,27 @@
</set>
</outcome>
<outcome value='Other'>
- <block>
+ <block atomic='true'>
<set>
<parameter name='vnf-index' value='`$service-data.vnfs.vnf_length`' />
</set>
<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >
<switch test='`$vnf-topology-operation-input.vnf-information.vnf-id == $service-data.vnfs.vnf[$idx].vnf-id`'>
<outcome value='true'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'VNF id ' + $service-data.vnfs.vnf[$idx].vnf-id
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'VNF id ' + $service-data.vnfs.vnf[$idx].vnf-id
+ ' already exists'`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
</for>
@@ -116,20 +168,36 @@
key="instance-group.id = $vnf-topology-operation-input.vnf-request-input.vnf-network-instance-group-ids[$inst-group-index].vnf-network-instance-group-id"
pfx='aai.instance-group' local-only='false' >
<outcome value='not-found'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Cannot find instance group id ' +
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Cannot find instance group id ' +
$vnf-topology-operation-input.vnf-request-input.vnf-network-instance-group-ids[$inst-group-index].vnf-network-instance-group-id
+ ' in AAI'`" />
- </return>
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error retrieving instance-group from AAI" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error retrieving instance-group from AAI" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</get-resource>
<for index='rel-index' start='0' end='`$aai.instance-group.relationship-list.relationship_length`' >
@@ -140,20 +208,37 @@
key="collection.collection-id = $aai.instance-group.relationship-list.relationship[$rel-index].relationship-data[0].relationship-value"
pfx='aai.collection' local-only='false' >
<outcome value='not-found'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Cannot find collection ' +
- $aai.instance-group.relationship-list.relationship[$rel-index].relationship-data[0].relationship-value
- + ' in AAI'`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Unable to find AAI relationship from collection '
+ + $aai.instance-group.relationship-list.relationship[$rel-index].relationship-data[0].relationship-value
+ + ' to service instance'`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="System error retrieving collection from AAI" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Failed to get network service instance '
+ + $network-service-instance + ' from MD-SAL'`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='success'>
<block atomic="true">
@@ -175,13 +260,22 @@
</for>
<switch test='`$found-network-instance-group`'>
<outcome value='false'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Could not find network instance group ' +
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Could not find network instance group ' +
$vnf-topology-operation-input.vnf-request-input.vnf-network-instance-group-ids[$inst-group-index].vnf-network-instance-group-id
- + ' in MD-SAL'`" />
- </return>
+ + ' in MD-SAL service instance '
+ + $network-service-instance`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
<set>
@@ -235,18 +329,34 @@
<block></block>
</outcome>
<outcome value='N'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="No vnf-name was received but ecomp-generated-naming is not Y" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="No vnf-name was received but ecomp-generated-naming is not Y" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="No vnf-name was received but ecomp-generated-naming is not Y" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="No vnf-name was received but ecomp-generated-naming is not Y" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
</switch>
<switch test='`$db.vf-model.naming-policy`'>
@@ -262,11 +372,19 @@
</set>
<call module='GENERIC-RESOURCE-API' rpc='generate-unique-name' mode='sync' >
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`$generate-unique-name-output.error-message`" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`$generate-unique-name-output.error-message`" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='success'>
<set>
@@ -287,11 +405,19 @@
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' >
<outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Unable to generate VNF name" />
- </return>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Unable to generate VNF name" />
+ </set>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
</outcome>
<outcome value='success'>
<set>
@@ -385,7 +511,10 @@
depth='all'"
pfx='aai.cloud-region' local-only='false' >
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Cloud region not found in AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -393,16 +522,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Cloud region not found in AAI" />
- </return>
</block>
</outcome>
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error retrieving cloud region from AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -410,12 +543,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error retrieving cloud region from AAI" />
- </return>
</block>
</outcome>
</get-resource>
@@ -439,7 +573,10 @@
</for>
<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.aic-clli`'>
<outcome value=''>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Unable to find aic-clli in AAI for aic-cloud-region ' + $vnf-topology-operation-input.vnf-request-input.aic-cloud-region`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -447,12 +584,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unable to find aic-clli in AAI for aic-cloud-region ' + $vnf-topology-operation-input.vnf-request-input.aic-cloud-region`" />
- </return>
</block>
</outcome>
</switch>
@@ -460,7 +598,10 @@
key='SELECT * from VF_TO_NETWORK_ROLE_MAPPING WHERE vf_customization_uuid = $vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid'
pfx='db.vf-network-role-mapping[]'>
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error reading VF_TO_NETWORK_ROLE_MAPPING table" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -468,12 +609,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error reading VF_TO_NETWORK_ROLE_MAPPING table" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
@@ -507,7 +649,10 @@
pfx='aai.l3-network' local-only='false'
>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Unable to find l3-network in AAI for network role ' + $db.vf-network-role-mapping[$role-index].network-role`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -515,18 +660,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No active l3-network found in AAI with cloud_region_id '
- + $vnf-topology-operation-input.vnf-request-input.aic-cloud-region + ' and network_role '
- + $db.vf-network-role-mapping[$network-index].network-role`" />
- </return>
</block>
</outcome>
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error retrieving l3-network from AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -534,12 +681,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error retrieving l3-network from AAI" />
- </return>
</block>
</outcome>
</get-resource>
@@ -622,7 +770,10 @@
</block>
<switch test='`$l3-network-id`'>
<outcome value='-1'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'Unable to find l3-network in AAI for network role ' + $db.vf-network-role-mapping[$role-index].network-role`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -630,12 +781,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unable to find l3-network in AAI for network role ' + $db.vf-network-role-mapping[$role-index].network-role`" />
- </return>
</block>
</outcome>
</switch>
@@ -733,7 +885,10 @@
and network_role = $db.vf-network-role-mapping[$role-index].network-role'
pfx='db.vnf-related-network-role[]'>
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error reading VNF_RELATED_NETWORK_ROLE table" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -741,12 +896,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error reading VNF_RELATED_NETWORK_ROLE table" />
- </return>
</block>
</outcome>
<outcome value='success'>
@@ -771,7 +927,14 @@
<parameter name='httpMethod' value='GET' />
<parameter name="responsePrefix" value="mdsal-ntis" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`
+ 'Error retrieving network-topology-identifier-structure for service instance '
+ + $network-service-instance-id
+ + ' and network-id '
+ + $l3-network-id`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -779,16 +942,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`
- 'Error retrieving network-topology-identifier-structure for service instance '
- + $network-service-instance-id
- + ' and network-id '
- + $l3-network-id`" />
- </return>
</block>
</outcome>
</execute>
@@ -808,7 +968,10 @@
<parameter name="start_length" value="1" />
<parameter name="query" value="/query/owning-entity-fromService-instance" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error getting owning entity from service instance" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -816,16 +979,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error getting owning entity from service instance" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Unable to find owning entity from service instance" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -833,12 +1000,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Unable to find owning entity from service instance" />
- </return>
</block>
</outcome>
</save>
@@ -865,7 +1033,10 @@
<parameter name="query" value="`'/query/getNetworks?networkRole=' + $db.vnf-related-network-role[$rel-network-role-index].related-network-role
+ '&amp;cloudRegionId=' + $vnf-topology-operation-input.vnf-request-input.aic-cloud-region`" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error calling getNetworks custom query in AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -873,16 +1044,21 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error calling getNetworks custom query in AAI" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No l3-network returned from getNetworks custom query for related network role '
+ + $db.vnf-related-network-role[0].related-network-role`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -890,13 +1066,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No l3-network returned from getNetworks custom query for related network role '
- + $db.vnf-related-network-role[0].related-network-role`" />
- </return>
</block>
</outcome>
</save>
@@ -919,7 +1095,10 @@
pfx='aai.vlan-tag' local-only='false'
>
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error getting vlan-tag object from AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -927,12 +1106,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error getting vlan-tag object from AAI" />
- </return>
</block>
</outcome>
<outcome value='success'>
@@ -984,7 +1164,11 @@
<outcome value=''>
<switch test='`$db.vf-model.avail-zone-max-count &gt; 0`'>
<outcome value='true'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No availability zones found in AAI for cloud region '
+ + $vnf-topology-operation-input.vnf-request-input.aic-cloud-region`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -992,13 +1176,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No availability zones found in AAI for cloud region '
- + $vnf-topology-operation-input.vnf-request-input.aic-cloud-region`" />
- </return>
</block>
</outcome>
<outcome value='false'>
@@ -1027,7 +1211,10 @@
<parameter name="relationship-list.relationship[0].relationship-data[2].relationship-key" value="availability-zone.availability-zone-name" />
<parameter name="relationship-list.relationship[0].relationship-data[2].relationship-value" value="`$aai.cloud-region.availability-zones.availability-zone[$idx].availability-zone-name`" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error updating generic-vnf in AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1035,16 +1222,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error updating generic-vnf in AAI" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1052,12 +1243,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
- </return>
</block>
</outcome>
</save>
@@ -1079,7 +1271,10 @@
<parameter name="relationship-list.relationship[0].relationship-data[0].relationship-key" value="l3-network.network-id" />
<parameter name="relationship-list.relationship[0].relationship-data[0].relationship-value" value="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-resource-assignments.vnf-networks.vnf-network[$vnf-nw-index].network-id`" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error updating generic-vnf in AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1087,16 +1282,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error updating generic-vnf in AAI" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1104,12 +1303,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
- </return>
</block>
</outcome>
</save>
@@ -1141,7 +1341,10 @@
<parameter name="in-maint" value="true" />
<parameter name="selflink" value="`$vnf-object-path`" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error updating selflink in generic-vnf in AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1149,16 +1352,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error updating selflink in generic-vnf in AAI" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1166,12 +1373,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
- </return>
</block>
</outcome>
</update>
@@ -1186,7 +1394,10 @@
value="`'/aai/v$/network/instance-groups/instance-group/'
+ $vnf-topology-operation-input.vnf-request-input.vnf-network-instance-group-ids[$inst-group-index].vnf-network-instance-group-id`" />
<outcome value='failure'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error updating relationship in generic-vnf in AAI" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1194,16 +1405,20 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error updating relationship in generic-vnf in AAI" />
- </return>
</block>
</outcome>
<outcome value='not-found'>
- <block>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
+ </set>
<block atomic="true">
<set>
<parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
@@ -1211,12 +1426,13 @@
<parameter name='naming-policy-generate-name-input.action' value='DELETE' />
</set>
<call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
</block>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'No generic-vnf found in AAI for vnf ID ' + $service-data.vnfs.vnf[$vnf-index].vnf-id`" />
- </return>
</block>
</outcome>
</save>
@@ -1234,9 +1450,79 @@
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.last-rpc-action' value='`$vnf-topology-operation-input.sdnc-request-header.svc-action`' />
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />
</set>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$prop.restapi.vnf-assign`"/>
+ <parameter name="outputPath" value="tmp.part"/>
+ <parameter name="target" value="{service-instance-id}"/>
+ <parameter name="replacement" value="`$service-data.service-topology.service-topology-identifier.service-instance-id`"/>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >
+ <parameter name="source" value="`$tmp.part`"/>
+ <parameter name="outputPath" value="tmp.vnf.url"/>
+ <parameter name="target" value="{vnf-id}"/>
+ <parameter name="replacement" value="`$service-data.vnfs.vnf[$vnf-index].vnf-id`"/>
+ </execute>
+ <set>
+ <parameter name='vnf-data.' value='service-data.vnfs.vnf[$vnf-index].vnf-data.' />
+ </set>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name='templateFileName' value="`$prop.restapi.templateDir + '/' + 'vnf-data-assign.json'`" />
+ <parameter name='restapiUrl' value="`$prop.controller.url + $tmp.vnf.url`" />
+ <parameter name='restapiUser' value='`$prop.controller.user`' />
+ <parameter name='restapiPassword' value='`$prop.controller.pwd`' />
+ <parameter name='format' value='json' />
+ <parameter name='httpMethod' value='PUT' />
+ <parameter name="responsePrefix" value="vnf-assign" />
+ <outcome value='failure'>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error doing PUT of vnf-data" />
+ </set>
+ <block atomic="true">
+ <set>
+ <parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
+ <parameter name='naming-policy-generate-name-input.context-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />
+ <parameter name='naming-policy-generate-name-input.action' value='DELETE' />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
+ </outcome>
+ <outcome value='not-found'>
+ <block atomic="true">
+ <set>
+ <parameter name="error-message" value="Error doing PUT of vnf-data" />
+ </set>
+ <block atomic="true">
+ <set>
+ <parameter name='naming-policy-generate-name-input.naming-type' value='VNF' />
+ <parameter name='naming-policy-generate-name-input.context-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />
+ <parameter name='naming-policy-generate-name-input.action' value='DELETE' />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='naming-policy-generate-name' mode='sync' ></call>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </block>
+ </outcome>
+ </execute>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='printContext' >
<parameter name='filename' value='/var/tmp/bgb-vnf.log' />
</execute>
+ <set>
+ <parameter name="so.response-code" value="200" />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='send-so-response' mode='sync' ></call>
<return status='success'>
<parameter name="ack-final-indicator" value="Y" />
<parameter name="error-code" value="200" />
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-async.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-async.xml
new file mode 100644
index 00000000..69175f2f
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation-async.xml
@@ -0,0 +1,28 @@
+<service-logic
+ xmlns='http://www.onap.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ <method rpc='vnf-topology-operation-async' mode='sync'>
+ <block atomic="true">
+ <set>
+ <parameter name='skip-mdsal-update' value='Y' />
+ </set>
+ <switch test='`$vnf-topology-operation-input.sdnc-request-header.svc-action`'>
+ <outcome value='assign'>
+ <call module='GENERIC-RESOURCE-API' rpc='vnf-topology-operation-assign' mode='sync' ></call>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`$vnf-topology-operation-input.sdnc-request-header.svc-action + ' is not a valid svc-action'`" />
+ </return>
+ </outcome>
+ </switch>
+ <return status='success'>
+ <parameter name="ack-final-indicator" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </method>
+</service-logic> \ No newline at end of file
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation.xml
index cabcce51..ecee104f 100644
--- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation.xml
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_vnf-topology-operation.xml
@@ -6,7 +6,14 @@
<call module='GENERIC-RESOURCE-API' rpc='validate-vnf-input' mode='sync' ></call>
<switch test='`$vnf-topology-operation-input.sdnc-request-header.svc-action`'>
<outcome value='assign'>
- <call module='GENERIC-RESOURCE-API' rpc='vnf-topology-operation-assign' mode='sync' ></call>
+ <block atomic="true">
+ <set>
+ <parameter name='skip-mdsal-update' value='Y' />
+ </set>
+ <set>
+ <parameter name='ack-final' value='N' />
+ </set>
+ </block>
</outcome>
<outcome value='activate'>
<block atomic="true">