diff options
author | Cheung, Pat (kc1472) <kc1472@att.com> | 2020-05-01 01:01:06 +0000 |
---|---|---|
committer | Dan Timoney <dtimoney@att.com> | 2020-05-01 13:17:48 +0000 |
commit | 695b770064bd338191803296d67d9482e0951771 (patch) | |
tree | 8289d4aa42d852eb87edeb996fc5ba8a09401364 /platform-logic/generic-resource-api/src/main/xml | |
parent | 3ffdb6571e187dea4d6491d8bdd832f5f4e2872f (diff) |
self-serve DG fix
default value to success when RA returns it as emptystring and object status is success
Issue-ID: SDNC-1140
Signed-off-by: Cheung, Pat (kc1472) <kc1472@att.com>
Change-Id: I0a38d525d54a83c2863b73d944935defbb02b495
(cherry picked from commit ad9e8072cf43eead5021c526bb8397e7720b900c [formerly 1df36cd2a20f26dfa1c80bc5c3baaa03140f1987])
Former-commit-id: ceb230e77fe7b3c32d60772687d9955e14721214
Diffstat (limited to 'platform-logic/generic-resource-api/src/main/xml')
2 files changed, 42 insertions, 10 deletions
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vfmodule-mapping-ra-response.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vfmodule-mapping-ra-response.xml index 4539ae13..75f5a3fe 100644 --- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vfmodule-mapping-ra-response.xml +++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vfmodule-mapping-ra-response.xml @@ -12,6 +12,9 @@ </return>
</outcome>
</switch>
+ <set>
+ <parameter name='CONSTANT' value='success'/>
+ </set>
<for silentFailure='true' index='vdns-index' start='0' end='`$jsonContextPrefix.resolution-summary_length`' >
<block atomic="true">
<set>
@@ -42,9 +45,22 @@ <set>
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.vf-module-parameters.param[$highnum].name'
value='`$jsonContextPrefix.resolution-summary[$vdns-index].name`'/>
- <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.vf-module-parameters.param[$highnum].value'
- value='`$jsonContextPrefix.resolution-summary[$vdns-index].value`'/>
</set>
+ <switch test="`$jsonContextPrefix.resolution-summary[$vdns-index].status == 'success' and
+ $jsonContextPrefix.resolution-summary[$vdns-index].value == ''`">
+ <outcome value='true'>
+ <set>
+ <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.vf-module-parameters.param[$highnum].value`'
+ value='`$CONSTANT`'/>
+ </set>
+ </outcome>
+ <outcome value='false'>
+ <set>
+ <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.vf-module-parameters.param[$highnum].value`'
+ value='`$jsonContextPrefix.resolution-summary[$vdns-index].value`'/>
+ </set>
+ </outcome>
+ </switch>
<set>
<parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-module-index].vf-module-data.vf-module-topology.vf-module-parameters.param[$highnum].resource-resolution-data.capability-name`'
value='`$jsonContextPrefix.resolution-summary[$vdns-index].dictionary-source`'/>
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vnf-mapping-ra-response.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vnf-mapping-ra-response.xml index 1be42fa4..551364fb 100644 --- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vnf-mapping-ra-response.xml +++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_self-serve-process-vnf-mapping-ra-response.xml @@ -12,6 +12,9 @@ </return>
</outcome>
</switch>
+ <set>
+ <parameter name='CONSTANT' value='success'/>
+ </set>
<for silentFailure='true' index='vdns-index' start='0' end='`$jsonContextPrefix.resolution-summary_length`' >
<block atomic="true">
<set>
@@ -42,15 +45,22 @@ <set>
<parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].name`'
value='`$jsonContextPrefix.resolution-summary[$vdns-index].name`'/>
- <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].value`'
- value='`$jsonContextPrefix.resolution-summary[$vdns-index].value`'/>
- </set>
- <set>
- <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].resource-resolution-data.capability-name`'
- value='`$jsonContextPrefix.resolution-summary[$vdns-index].dictionary-source`'/>
- <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].resource-resolution-data.status`'
- value='`$jsonContextPrefix.resolution-summary[$vdns-index].status`'/>
</set>
+ <switch test="`$jsonContextPrefix.resolution-summary[$vdns-index].status == 'success' and
+ $jsonContextPrefix.resolution-summary[$vdns-index].value == ''`">
+ <outcome value='true'>
+ <set>
+ <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].value`'
+ value='`$CONSTANT`'/>
+ </set>
+ </outcome>
+ <outcome value='false'>
+ <set>
+ <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].value`'
+ value='`$jsonContextPrefix.resolution-summary[$vdns-index].value`'/>
+ </set>
+ </outcome>
+ </switch>
<for silentFailure='true' index='kid-index' start='0' end='`$jsonContextPrefix.resolution-summary[$vdns-index].key-identifiers_length`' >
<set>
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].resource-resolution-data.resource-key[$kid-index].name'
@@ -60,6 +70,12 @@ </set>
</for>
<set>
+ <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].resource-resolution-data.capability-name`'
+ value='`$jsonContextPrefix.resolution-summary[$vdns-index].dictionary-source`'/>
+ <parameter name='`service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].resource-resolution-data.status`'
+ value='`$jsonContextPrefix.resolution-summary[$vdns-index].status`'/>
+ </set>
+ <set>
<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.vnf-parameters-data.param[$highnum].resource-resolution-data.resource-key_length'
value='`$jsonContextPrefix.resolution-summary[$vdns-index].key-identifiers_length`' />
</set>
|