diff options
author | 2020-05-13 05:07:55 +0000 | |
---|---|---|
committer | 2020-05-13 05:07:55 +0000 | |
commit | fb18306b26c323d9f0fbe8e0b5f049e9ed85f75e (patch) | |
tree | 6d012b378f00997d850001b1b3c10e291ab46d23 /platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml | |
parent | 1861e0d23547acffeb5c44485104f11a40a8fda0 (diff) |
Adding local-link-connectivity-list (llcl) information to match ttp and tp locally (to support NNI-based Service creation use-case).
- This is needed for F release
Issue-ID: SDNC-1184
Signed-off-by: Hesam Rahimi <hesam.rahimi@huawei.com>
Change-Id: I24f1ef56884b874baed029182a984945080af769
Former-commit-id: 4ff90dd1689d772865399ab5a995119981b127e1
Diffstat (limited to 'platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml')
-rw-r--r-- | platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml | 381 |
1 files changed, 209 insertions, 172 deletions
diff --git a/platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml b/platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml index 7159b23a..3ea459a5 100644 --- a/platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml +++ b/platform-logic/generic-resource-api/src/main/xml/sotn_nni/GENERIC-RESOURCE-API_sotn-get-otn-tunnel-path-from-oof.xml @@ -1,13 +1,11 @@ -<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='sotn-get-otn-tunnel-path-from-oof' mode='sync'>
+<service-logic xsi:schemaLocation="http://www.onap.org/sdnc/svclogic ./svclogic.xsd" module="GENERIC-RESOURCE-API" version="${project.version}">
+ <method rpc="sotn-get-otn-tunnel-path-from-oof" mode="sync">
<block atomic="true">
- <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
- <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/' + $prop.restapi.oof-getpath.templatefile`" />
- <parameter name="restapiUrl" value="`$prop.restapi.connection-oof-url`" />
- <parameter name="restapiUser" value="`$prop.oof.user`" />
- <parameter name="restapiPassword" value="`$prop.oof.password`" />
+ <execute plugin="org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode" method="sendRequest">
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/' + $prop.restapi.oof-getpath.templatefile`"/>
+ <parameter name="restapiUrl" value="`$prop.restapi.connection-oof-url`"/>
+ <parameter name="restapiUser" value="`$prop.oof.user`"/>
+ <parameter name="restapiPassword" value="`$prop.oof.password`"/>
<parameter name="format" value="json"/>
<parameter name="httpMethod" value="post"/>
<parameter name="responsePrefix" value="otn-oof"/>
@@ -15,95 +13,106 @@ <parameter name="trustStorePassword" value="adminadmin"/>
<parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
<parameter name="keyStorePassword" value="adminadmin"/>
- <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
- <outcome value='failure'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="Error executing OOF api" />
+ <parameter name="customHttpHeaders" value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`"/>
+ <outcome value="failure">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="Error executing OOF api"/>
</return>
</outcome>
- <outcome value='success'>
- <block></block>
+ <outcome value="success">
+ <block/>
</outcome>
</execute>
- <for index='vidx' start='0' end='`$otn-oof.solutions_length`' >
+ <for index="vidx" start="0" end="`$otn-oof.solutions_length`">
<block atomic="true">
<set>
- <parameter name='otn-oof.link-name' value='`$otn-oof.solutions[$vidx].link`' />
+ <parameter name="otn-oof.link-name" value="`$otn-oof.solutions[$vidx].link`"/>
</set>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="logical-link"
- key="logical-link.link-name = $otn-oof.link-name"
- pfx='tmp.aai.cross-link' local-only='false' >
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="logical-link" key="logical-link.link-name = $otn-oof.link-name" pfx="tmp.aai.cross-link" local-only="false">
<!--AND depth = '0'"-->
- <outcome value='success'>
+ <outcome value="success">
<block>
- <switch test='`$tmp.aai.cross-link.link-role`'>
- <outcome value='cross-domain'>
+ <switch test="`$tmp.aai.cross-link.link-role`">
+ <outcome value="cross-domain">
<block atomic="true">
- <set>
- <parameter name='tmp.cross-link.src-ltpId' value="`$tmp.aai.cross-link.relationship-list.relationship[0].relationship-data[1].relationship-value`" />
- <parameter name='tmp.cross-link.dst-ltpId' value="`$tmp.aai.cross-link.relationship-list.relationship[1].relationship-data[1].relationship-value`" />
- <parameter name='tmp.src-pnf-name' value="`$tmp.aai.cross-link.relationship-list.relationship[0].relationship-data[0].relationship-value`" />
- <parameter name='tmp.dst-pnf-name' value="`$tmp.aai.cross-link.relationship-list.relationship[1].relationship-data[0].relationship-value`" />
- </set>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="p-interface"
- key="pnf.pnf-name = $tmp.src-pnf-name
- AND p-interface.interface-name = $tmp.cross-link.src-ltpId"
- pfx='tmp.aai.src-tp' local-only='false' >
+ <for index="lridx" start="0" end="`$tmp.aai.cross-link.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].related-to`">
+ <outcome value="p-interface">
+ <block>
+ <set>
+ <parameter name="tmp.cross-link.src-ltpId" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].relationship-data[1].relationship-value`"/>
+ <parameter name="tmp.cross-link.dst-ltpId" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx + 1].relationship-data[1].relationship-value`"/>
+ <parameter name="tmp.src-pnf-name" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].relationship-data[0].relationship-value`"/>
+ <parameter name="tmp.dst-pnf-name" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx + 1].relationship-data[0].relationship-value`"/>
+ </set>
+ <break/>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="p-interface" key="pnf.pnf-name = $tmp.src-pnf-name AND p-interface.interface-name = $tmp.cross-link.src-ltpId" pfx="tmp.aai.src-tp" local-only="false">
<!--AND depth = '0'"-->
- <outcome value='success'>
+ <outcome value="success">
<block>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="pnf"
- key="pnf.pnf-name = $tmp.src-pnf-name"
- pfx='tmp.aai.src-pnf' local-only='false' >
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="pnf" key="pnf.pnf-name = $tmp.src-pnf-name" pfx="tmp.aai.src-pnf" local-only="false">
<!--AND depth = '0'"-->
- <outcome value='success'>
+ <outcome value="success">
<block>
<set>
- <parameter name='domain-A.node-id' value="`$tmp.aai.src-pnf.pnf-id`" />
- <parameter name='domain-A.tpn' value='1' />
+ <parameter name="domain-A.node-id" value="`$tmp.aai.src-pnf.pnf-id`"/>
+ <parameter name="domain-A.tpn" value="1"/>
</set>
- <for silentFailure='true' index='vidx' start='0' end='`$tmp.aai.src-pnf.relationship-list.relationship_length`' >
- <switch test='`$tmp.aai.src-pnf.relationship-list.relationship[$vidx].related-to`'>
- <outcome value='tunnel-termination-point'>
+ <for silentFailure="true" index="vidx" start="0" end="`$tmp.aai.src-pnf.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.src-pnf.relationship-list.relationship[$vidx].related-to`">
+ <outcome value="tunnel-termination-point">
<block atomic="true">
<set>
- <parameter name='tmp.src-ttp-id' value="`$tmp.aai.src-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`" />
+ <parameter name="tmp.src-ttp-id" value="`$tmp.aai.src-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`"/>
</set>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="tunnel-termination-point"
- key="tunnel-termination-point.ttp-id = $tmp.src-ttp-id
- AND depth = '0'"
- pfx='tmp.aai.src-ttp' local-only='false' >
- <outcome value='success'>
- <set>
- <parameter name='domain-A.ttp-id' value="`$tmp.aai.src-ttp.ttp-id`" />
- </set>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="tunnel-termination-point" key="tunnel-termination-point.ttp-id = $tmp.src-ttp-id AND depth = '0'" pfx="tmp.aai.src-ttp" local-only="false">
+ <outcome value="success">
+ <block atomic="true">
+ <switch test="`$tmp.aai.src-ttp.relationship-list.relationship_length`">
+ <outcome value="">
+ <block/>
+ </outcome>
+ <outcome value="0">
+ <block/>
+ </outcome>
+ <outcome value="Other">
+ <for silentFailure="true" index="vidx" start="0" end="`$tmp.aai.src-ttp.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.src-ttp.relationship-list.relationship[$vidx].related-to`">
+ <outcome value="p-interface">
+ <block atomic="true">
+ <set>
+ <parameter name="domain-A.ttp-id" value="`$tmp.aai.src-ttp.tunnel-tp-id`"/>
+ </set>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ </switch>
+ </block>
</outcome>
</get-resource>
</block>
</outcome>
- <outcome value='network-resource'>
+ <outcome value="network-resource">
<block atomic="true">
<set>
- <parameter name='tmp.domain-A.network-id' value="`$tmp.aai.src-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`" />
+ <parameter name="tmp.domain-A.network-id" value="`$tmp.aai.src-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`"/>
</set>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="network-resource"
- key="network-resource.network-id = $tmp.domain-A.network-id
- AND depth = '0'"
- pfx='tmp.aai.src-network-resource' local-only='false' >
- <outcome value='success'>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="network-resource" key="network-resource.network-id = $tmp.domain-A.network-id AND depth = '0'" pfx="tmp.aai.src-network-resource" local-only="false">
+ <outcome value="success">
<set>
- <parameter name='domain-A.network-id' value="`$tmp.aai.src-network-resource.network-id`" />
- <parameter name='domain-A.provider-id' value="`$tmp.aai.src-network-resource.provider-id`" />
- <parameter name='domain-A.client-id' value="`$tmp.aai.src-network-resource.client-id`" />
- <parameter name='domain-A.te-topo-id' value="`$tmp.aai.src-network-resource.te-topo-id`" />
- <parameter name='domain-A.network-type' value="`$tmp.aai.src-network-resource.network-type`" />
+ <parameter name="domain-A.network-id" value="`$tmp.aai.src-network-resource.network-id`"/>
+ <parameter name="domain-A.provider-id" value="`$tmp.aai.src-network-resource.provider-id`"/>
+ <parameter name="domain-A.client-id" value="`$tmp.aai.src-network-resource.client-id`"/>
+ <parameter name="domain-A.te-topo-id" value="`$tmp.aai.src-network-resource.te-topo-id`"/>
+ <parameter name="domain-A.network-type" value="`$tmp.aai.src-network-resource.network-type`"/>
</set>
</outcome>
</get-resource>
@@ -113,94 +122,99 @@ </for>
</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="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="not-found">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
- <outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="Other">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
</get-resource>
</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="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="not-found">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
- <outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="Other">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
</get-resource>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="p-interface"
- key="pnf.pnf-name = $tmp.src-pnf-name
- AND p-interface.interface-name = $tmp.cross-link.src-ltpId"
- pfx='tmp.aai.dst-tp' local-only='false' >
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="p-interface" key="pnf.pnf-name = $tmp.src-pnf-name AND p-interface.interface-name = $tmp.cross-link.src-ltpId" pfx="tmp.aai.dst-tp" local-only="false">
<!--AND depth = '0'"-->
- <outcome value='success'>
+ <outcome value="success">
<block>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="pnf"
- key="pnf.pnf-name = $tmp.dst-pnf-name"
- pfx='tmp.aai.dst-pnf' local-only='false' >
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="pnf" key="pnf.pnf-name = $tmp.dst-pnf-name" pfx="tmp.aai.dst-pnf" local-only="false">
<!--AND depth = '0'"-->
- <outcome value='success'>
+ <outcome value="success">
<block>
<set>
- <parameter name='domain-B.node-id' value="`$tmp.aai.dst-pnf.pnf-id`" />
- <parameter name='domain-B.tpn' value='1' />
+ <parameter name="domain-B.node-id" value="`$tmp.aai.dst-pnf.pnf-id`"/>
+ <parameter name="domain-B.tpn" value="1"/>
</set>
- <for silentFailure='true' index='vidx' start='0' end='`$tmp.aai.dst-pnf.relationship-list.relationship_length`' >
- <switch test='`$tmp.aai.dst-pnf.relationship-list.relationship[$vidx].related-to`'>
- <outcome value='tunnel-termination-point'>
+ <for silentFailure="true" index="vidx" start="0" end="`$tmp.aai.dst-pnf.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.dst-pnf.relationship-list.relationship[$vidx].related-to`">
+ <outcome value="tunnel-termination-point">
<block atomic="true">
<set>
- <parameter name='tmp.dst-ttp-id' value="`$tmp.aai.dst-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`" />
+ <parameter name="tmp.dst-ttp-id" value="`$tmp.aai.dst-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`"/>
</set>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="tunnel-termination-point"
- key="tunnel-termination-point.ttp-id = $tmp.dst-ttp-id
- AND depth = '0'"
- pfx='tmp.aai.dst-ttp' local-only='false' >
- <outcome value='success'>
- <set>
- <parameter name='domain-B.ttp-id' value="`$tmp.aai.dst-ttp.ttp-id`" />
- </set>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="tunnel-termination-point" key="tunnel-termination-point.ttp-id = $tmp.dst-ttp-id AND depth = '0'" pfx="tmp.aai.dst-ttp" local-only="false">
+ <outcome value="success">
+ <block atomic="true">
+ <switch test="`$tmp.aai.dst-ttp.relationship-list.relationship_length`">
+ <outcome value="">
+ <block/>
+ </outcome>
+ <outcome value="0">
+ <block/>
+ </outcome>
+ <outcome value="Other">
+ <for silentFailure="true" index="vidx" start="0" end="`$tmp.aai.dst-ttp.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.dst-ttp.relationship-list.relationship[$vidx].related-to`">
+ <outcome value="p-interface">
+ <block atomic="true">
+ <set>
+ <parameter name="domain-B.ttp-id" value="`$tmp.aai.dst-ttp.tunnel-tp-id`"/>
+ </set>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ </switch>
+ </block>
</outcome>
</get-resource>
</block>
</outcome>
- <outcome value='network-resource'>
+ <outcome value="network-resource">
<block atomic="true">
<set>
- <parameter name='tmp.domain-B.network-id' value="`$tmp.aai.dst-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`" />
+ <parameter name="tmp.domain-B.network-id" value="`$tmp.aai.dst-pnf.relationship-list.relationship[$vidx].relationship-data[0].relationship-value`"/>
</set>
- <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
- resource="network-resource"
- key="network-resource.network-id = $tmp.domain-B.network-id
- AND depth = '0'"
- pfx='tmp.aai.dst-network-resource' local-only='false' >
- <outcome value='success'>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource="network-resource" key="network-resource.network-id = $tmp.domain-B.network-id AND depth = '0'" pfx="tmp.aai.dst-network-resource" local-only="false">
+ <outcome value="success">
<set>
- <parameter name='domain-B.network-id' value="`$tmp.aai.dst-network-resource.network-id`" />
- <parameter name='domain-B.provider-id' value="`$tmp.aai.dst-network-resource.provider-id`" />
- <parameter name='domain-B.client-id' value="`$tmp.aai.dst-network-resource.client-id`" />
- <parameter name='domain-B.te-topo-id' value="`$tmp.aai.dst-network-resource.te-topo-id`" />
- <parameter name='domain-B.network-type' value="`$tmp.aai.dst-network-resource.network-type`" />
+ <parameter name="domain-B.network-id" value="`$tmp.aai.dst-network-resource.network-id`"/>
+ <parameter name="domain-B.provider-id" value="`$tmp.aai.dst-network-resource.provider-id`"/>
+ <parameter name="domain-B.client-id" value="`$tmp.aai.dst-network-resource.client-id`"/>
+ <parameter name="domain-B.te-topo-id" value="`$tmp.aai.dst-network-resource.te-topo-id`"/>
+ <parameter name="domain-B.network-type" value="`$tmp.aai.dst-network-resource.network-type`"/>
</set>
</outcome>
</get-resource>
@@ -210,35 +224,35 @@ </for>
</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="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="not-found">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
- <outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="Other">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
</get-resource>
</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="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="not-found">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
- <outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="Other">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
</get-resource>
@@ -246,34 +260,57 @@ </block>
</outcome>
</switch>
- <switch test='`$vidx`'>
- <outcome value='0'>
- <set>
- <parameter name='tmp.oofsolutions-first-src-pnf-name' value="`$tmp.aai.cross-link.relationship-list.relationship[0].relationship-data[0].relationship-value`" />
- <parameter name='tmp.oofsolutions-first-src-ltpId' value="`$tmp.aai.cross-link.relationship-list.relationship[0].relationship-data[1].relationship-value`" />
- </set>
- </outcome>
- <outcome value='`$otn-oof.solutions_length - 1`'>
- <set>
- <parameter name='tmp.oofsolutions-last-dst-pnf-name' value="`$tmp.aai.cross-link.relationship-list.relationship[1].relationship-data[0].relationship-value`" />
- <parameter name='tmp.oofsolutions-last-dst-ltpId' value="`$tmp.aai.cross-link.relationship-list.relationship[1].relationship-data[1].relationship-value`" />
- </set>
+ <switch test="`length($tmp.aai.cross-link.relationship-list.relationship) == 0`">
+ <outcome value="true"/>
+ <outcome value="false">
+ <switch test="`$vidx`">
+ <outcome value="0">
+ <for index="lridx" start="0" end="`$tmp.aai.cross-link.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].related-to`">
+ <outcome value="p-interface">
+ <block>
+ <set>
+ <parameter name="tmp.oofsolutions-first-src-pnf-name" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].relationship-data[0].relationship-value`"/>
+ <parameter name="tmp.oofsolutions-first-src-ltpId" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].relationship-data[1].relationship-value`"/>
+ </set>
+ <break/>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ <outcome value="`$otn-oof.solutions_length - 1`">
+ <for index="lridx" start="0" end="`$tmp.aai.cross-link.relationship-list.relationship_length`">
+ <switch test="`$tmp.aai.cross-link.relationship-list.relationship[$lridx].related-to`">
+ <outcome value="p-interface">
+ <block>
+ <set>
+ <parameter name="tmp.oofsolutions-last-dst-pnf-name" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx + 1].relationship-data[0].relationship-value`"/>
+ <parameter name="tmp.oofsolutions-last-dst-ltpId" value="`$tmp.aai.cross-link.relationship-list.relationship[$lridx + 1].relationship-data[1].relationship-value`"/>
+ </set>
+ <break/>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ </switch>
</outcome>
</switch>
</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="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="not-found">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'An error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
- <outcome value='Other'>
- <return status='failure'>
- <parameter name='ack-final' value='Y'/>
- <parameter name="error-code" value="500" />
- <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`" />
+ <outcome value="Other">
+ <return status="failure">
+ <parameter name="ack-final" value="Y"/>
+ <parameter name="error-code" value="500"/>
+ <parameter name="error-message" value="`'Unexpected error occurred while querying pnf from AnAI with pnf-name = ' + $prop.connection-attachement.access-node-id`"/>
</return>
</outcome>
</get-resource>
|