diff options
author | 2018-08-24 19:21:33 +0530 | |
---|---|---|
committer | 2018-08-24 19:23:41 +0530 | |
commit | 07d173c059f15fe9959deec9650246b173a3b50c (patch) | |
tree | f7e63ec52f90602038b73500ce1c192b8774591f /platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml | |
parent | cc49cb7753ff820dada996ab1d56263243630395 (diff) |
SDWAN flow based end-end test and issue fix
SDWAN DGs and restapi templates issue fixes
Change-Id: I5d1d4e6cb17e9b187ea4f0942ca837472738fe62
Issue-ID: SDNC-357
Signed-off-by: Prakash.E <prakash.e@huawei.com>
Former-commit-id: b1da373ad0e08400b4c1f2a8cfbb69524df745a2
Diffstat (limited to 'platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml')
-rw-r--r-- | platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml | 62 |
1 files changed, 29 insertions, 33 deletions
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml index 59e03134..3879fdc1 100644 --- a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml +++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.xml @@ -144,7 +144,7 @@ </for>
<get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
resource="esr-thirdparty-sdnc"
- key="esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWAN-Controller AND
+ key="esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND
depth = '1'"
pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >
<outcome value='success'>
@@ -198,7 +198,7 @@ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
<parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
<parameter name="format" value="json"/>
- <parameter name="httpMethod" value="post"/>
+ <parameter name="httpMethod" value="put"/>
<parameter name="responsePrefix" value="portResp"/>
<parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.openecomp.client.jks"/>
<parameter name="trustStorePassword" value="adminadmin"/>
@@ -216,19 +216,10 @@ <block atomic="true"></block>
</outcome>
</execute>
- <for index="portidx" start="0" end="`$portResp_length`">
- <block>
- <switch test="`$portResp[$portidx].deviceId == $prop.deviceId`">
- <outcome value='true'>
- <set>
- <parameter name='prop.wan.devicePortId' value='`$portResp[$portidx].id`' />
- </set>
- </outcome>
- </switch>
- </block>
- </for>
+ <set>
+ <parameter name='prop.wan.devicePortId' value='`$portResp.success[0].id`' />
+ </set>
<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
- <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdwan-network-orchestration.json'`" />
<parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/network-orchestration-resources'`" />
<parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
<parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
@@ -251,19 +242,19 @@ <block atomic="true"></block>
</outcome>
</execute>
- <for index="tidx" start="0" end="`$transportNetworksResp.transportNetworks_length`">
+ <for index="tidx" start="0" end="`$transportNetworksResp.data.transportNetworks_length`">
<block>
- <switch test="`$transportNetworksResp.transportNetworks[$tidx].name == $prop.wan.transportNetworkName`">
+ <switch test="`$transportNetworksResp.data.transportNetworks[$tidx].name == $prop.wan.transportNetworkName`">
<outcome value='true'>
<set>
- <parameter name='prop.wan.transportNetworkId' value='`$transportNetworksResp[$tidx].id`' />
+ <parameter name='prop.wan.transportNetworkId' value='`$transportNetworksResp.data.transportNetworks[$tidx].id`' />
</set>
</outcome>
</switch>
</block>
</for>
<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >
- <parameter name="original_string" value='`$prop.ipAddress`'/>
+ <parameter name="original_string" value='`$prop.wan.ipAddress`'/>
<parameter name="regex" value="/"/>
<parameter name="ctx_memory_result_key" value="ipandMask"/>
<outcome value='success'>
@@ -303,26 +294,21 @@ <block atomic="true"></block>
</outcome>
</execute>
- <for index="wanPortidx" start="0" end="`$wanPortResp_length`">
- <block>
- <switch test="`$wanPortResp[$wanPortidx].deviceId == $prop.deviceId`">
- <outcome value='true'>
- <set>
- <parameter name='prop.wan.wanPortId' value='`$wanPortResp[$wanPortidx].id`' />
- </set>
- </outcome>
- </switch>
- </block>
- </for>
+ <set>
+ <parameter name='prop.wan.wanPortId' value='`$wanPortResp.success[0].id`' />
+ </set>
<set>
<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value='devicePortId' />
<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$prop.wan.devicePortId`' />
- <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1].name' value='wanPortId' />
- <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1].value' value='`$prop.wan.wanPortId`' />
- <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 2`' />
+ <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value='wanPortId' />
+ <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$prop.wan.wanPortId`' />
+ <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />
</set>
<set>
- <parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-id`' />
+ <!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /-->
<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='$vnf-topology-operation-input.sdnc-request-header.' />
<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='$vnf-topology-operation-input.request-information.' />
<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='$vnf-topology-operation-input.service-information.' />
@@ -336,6 +322,16 @@ <parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />
</set>
+ <update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='wan-port-config'
+ key='wan-port-config.id = $vnf-topology-operation-input.vnf-information.vnf-id' >
+ <parameter name="id" value="`$vnf-topology-operation-input.vnf-information.vnf-id`" />
+ <parameter name='operational-status' value='Active' />
+ <parameter name='device-port-id' value='`$prop.wan.devicePortId`' />
+ <parameter name='wan-port-id' value='`$prop.wan.wanPortId`' />
+ <parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />
+ <parameter name='model-invariant-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-invariant-uuid`' />
+ <parameter name='model-version-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-uuid`' />
+ </update>
<return status='success'>
<parameter name="ack-final-indicator" value="Y" />
<parameter name="error-code" value="200" />
|