summaryrefslogtreecommitdiffstats
path: root/platform-logic/generic-resource-api/src/main/xml
diff options
context:
space:
mode:
authorMarcus G K Williams <marcus.williams@intel.com>2017-09-27 11:01:59 -0700
committerMarcus G K Williams <marcus.williams@intel.com>2017-09-27 11:25:38 -0700
commit154635848d8cc96163815da880d582139eae7bc4 (patch)
tree4ea7c72b347972002e6dff299a2a0e77955611c4 /platform-logic/generic-resource-api/src/main/xml
parentc3e2005d4a8bc51460a8ad9661c8961ad8c6eaf4 (diff)
Add VoLTE l3-dci-connects DGs + xml
Issue-Id: SDNC-28 Change-Id: I1e1eea6dc91d4ec7fd3cb159b557e33ebef13c92 Signed-off-by: Marcus G K Williams <marcus.williams@intel.com> Former-commit-id: 933ae5b147fc5c72aacc40a2255545efc8f2a7cd
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_l3-dci-connects-network-topology-operation-activate.xml142
-rw-r--r--platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_l3-dci-connects-network-topology-operation-deactivate.xml69
2 files changed, 211 insertions, 0 deletions
diff --git a/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_l3-dci-connects-network-topology-operation-activate.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_l3-dci-connects-network-topology-operation-activate.xml
new file mode 100644
index 00000000..5e907e4d
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_l3-dci-connects-network-topology-operation-activate.xml
@@ -0,0 +1,142 @@
+<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='network-topology-operation-activate' mode='sync'>
+ <block atomic='true'>
+ <call module='GENERIC-RESOURCE-API' rpc='validate-network-input-parameters' mode='sync' ></call>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
+ resource="l3-dci-connects"
+ key="l3-dci-connects.id = $tmp.id AND depth = '1'"
+ pfx='tmp.aai.l3-dci-connects' local-only='false' >
+ <outcome value='success'>
+ <block></block>
+ </outcome>
+ <outcome value='not-found'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value='' />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value='' />
+ </return>
+ </outcome>
+ </get-resource>
+ <set>
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.url' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.serviceUrl`" />
+ <parameter name='prop.sdncRestApi.templateDir' value='/opt/onap/sdnc/data' />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.user' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.user-name`" />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.password' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.password`" />
+ </set>
+ <for index='idx' start='0' end='`$network-topology-operation-input.network-request-input.network-input-parameters.param_length`' >
+ <block>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'name'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.name' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'description'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.description' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'router_id'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.router_id' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'local_networks'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.local_networks' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'evpn_irts'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.evpn_irts' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'evpn_erts'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.evpn_erts' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'l3_vni'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.l3_vni' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ </block>
+ </for>
+ <execute plugin='com.att.sdnctl.sli.SliPluginUtils.SliPluginUtils' method='generateUUID' >
+ <parameter name="ctx-destination" value="prop.l3-dci-connects.id"/>
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value='' />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block></block>
+ </outcome>
+ </execute>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder">
+ <parameter name="logger" value="message-log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="GENERIC-RESOURCE-API.l3-dci-connects-network-topology-operation-activate"/>
+ <parameter name='field3' value='`$l3-dci-connects.name`' />
+ <parameter name='field3' value='`$l3-dci-connects.id`' />
+ <parameter name='field4' value='`$l3-dci-connects.description`' />
+ <parameter name='field5' value='`$l3-dci-connects.router_id`' />
+ <parameter name='field6' value='`$l3-dci-connects.local_networks`' />
+ <parameter name='field7' value='`$l3-dci-connects.evpn_irts`' />
+ <parameter name='field8' value='`$l3-dci-connects.evpn_erts`' />
+ <parameter name='field9' value='`$l3-dci-connects.l3_vni`' />
+ </record>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="$prop.sdncRestApi.tempDir +'/l3-dci-connects-template.json'"/>
+ <parameter name="restapiUrl" value="$prop.sdncRestApi.thirdpartySdnc.url +'/v2.0/l3-dci-connects'"/>
+ <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="responsePrefix" value="restapi-result"/>
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error updating md-sal for contrail-route-allotted-resource" />
+ </return>
+ </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="Error updating md-sal for contrail-route-allotted-resource" />
+ </return>
+ </outcome>
+ </execute>
+ <return status='success'>
+ <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_l3-dci-connects-network-topology-operation-deactivate.xml b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_l3-dci-connects-network-topology-operation-deactivate.xml
new file mode 100644
index 00000000..da74ae8d
--- /dev/null
+++ b/platform-logic/generic-resource-api/src/main/xml/GENERIC-RESOURCE-API_l3-dci-connects-network-topology-operation-deactivate.xml
@@ -0,0 +1,69 @@
+<service-logic
+ xmlns='http://www.openecomp.org/sdnc/svclogic'
+ xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.openecomp.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>
+ <method rpc='network-topology-operation-deactivate' mode='sync'>
+ <block atomic="true">
+ <call module='GENERIC-RESOURCE-API' rpc='validate-network-input-parameters' mode='sync' ></call>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
+ resource="l3-dci-connects"
+ key="l3-dci-connects.id AND depth = '1'"
+ pfx='tmp.aai.l3-dci-connects' local-only='false' >
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ <outcome value='not-found'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value='' />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value='' />
+ </return>
+ </outcome>
+ </get-resource>
+ <record plugin="org.openecomp.sdnc.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic.log"/>
+ <parameter name="Time" value="__TIMESTAMP__"/>
+ <parameter name="Method" value="network-topology-operation-deactivate"/>
+ <parameter name="SubMethod" value="l3-dci-connects"/>
+ <parameter name="L3DciConnectsId" value="`$l3-dci-connects.id`"/>
+ </record>
+ <set>
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.url' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.serviceUrl`" />
+ <parameter name='prop.sdncRestApi.templateDir' value='/opt/onap/sdnc/data' />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.user' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.user-name`" />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.password' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.password`" />
+ </set>
+ <switch test="`$network-topology-operation-input.network-request-input.network-input-parameters.l3-dci-connects.id`">
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value='' />
+ </return>
+ </outcome>
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.l3-dci-connects.id' value='`$network-topology-operation-input.network-request-input.network-input-parameters.l3-dci-connects.id.value`' />
+ </set>
+ </outcome>
+ </switch>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="restapiUrl" value="$prop.sdncRestApi.thirdpartySdnc.url + '/v2.0/l3-dci-connects/' + $prop.l3-dci-connects.id"/>
+ <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="delete"/>
+ <parameter name="responsePrefix" value="restapi-result"/>
+ </execute>
+ <return status='success'>
+ <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