Merge "DG changes for the closed loop and async support in MDONS"
[sdnc/oam.git] / platform-logic / datachange / src / main / xml / DataChange_esr-thirdparty-sdnc.xml
1 <service-logic\r
2     xmlns='http://www.onap.org/sdnc/svclogic'\r
3     xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='DataChange' version='${project.version}'>\r
4     <method rpc='esr-thirdparty-sdnc' mode='sync'>\r
5         <block atomic="true">\r
6             <call module='DataChange' rpc='validate-esr-thirdparty-sdnc-input' mode='sync' ></call>\r
7             <for index='idx' start='0' end='`$data-change-notification-input.key-data_length`' >\r
8                 <block>\r
9                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'service-url'`">\r
10                         <outcome value='true'>\r
11                             <set>\r
12                                 <parameter name='prop.sdncRestApi.thirdpartySdnc.url' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
13                             </set>\r
14                         </outcome>\r
15                     </switch>\r
16                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'user-name'`">\r
17                         <outcome value='true'>\r
18                             <set>\r
19                                 <parameter name='prop.sdncRestApi.thirdpartySdnc.user' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
20                             </set>\r
21                         </outcome>\r
22                     </switch>\r
23                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'password'`">\r
24                         <outcome value='true'>\r
25                             <set>\r
26                                 <parameter name='prop.sdncRestApi.thirdpartySdnc.password' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
27                             </set>\r
28                         </outcome>\r
29                     </switch>\r
30                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'esr-system-info-id'`">\r
31                         <outcome value='true'>\r
32                             <set>\r
33                                 <parameter name='prop.sdncRestApi.thirdpartySdnc.system-info-id' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
34                             </set>\r
35                         </outcome>\r
36                     </switch>\r
37                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'thirdparty-sdnc-id'`">\r
38                         <outcome value='true'>\r
39                             <set>\r
40                                 <parameter name='prop.sdncRestApi.thirdpartySdnc.id' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
41                             </set>\r
42                         </outcome>\r
43                     </switch>\r
44                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'type'`">\r
45                         <outcome value='true'>\r
46                             <set>\r
47                                 <parameter name='prop.sdncRestApi.type' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
48                             </set>\r
49                         </outcome>\r
50                     </switch>\r
51                     <switch test="`$data-change-notification-input.key-data[$idx].key-name == 'vendor'`">\r
52                         <outcome value='true'>\r
53                             <set>\r
54                                 <parameter name='prop.sdncRestApi.vendor' value='`$data-change-notification-input.key-data[$idx].key-value`' />\r
55                             </set>\r
56                         </outcome>\r
57                     </switch>\r
58                 </block>\r
59             </for>\r
60             <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">\r
61                 <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic.log"/>\r
62                 <parameter name="field1" value="__TIMESTAMP__"/>\r
63                 <parameter name="field2" value="data-change-notification"/>\r
64                 <parameter name="field3" value="Config"/>\r
65                 <parameter name="field4" value="`service-url`"/>\r
66                 <parameter name="field5" value="`$prop.sdncRestApi.thirdpartySdnc.url`"/>\r
67             </record>\r
68             <call module='DataChange' rpc='esr-thirdparty-sdnc-discovery' mode='sync' ></call>\r
69         </block>\r
70     </method>\r
71 </service-logic>