1 # Copyright (c) 2016 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
6 # http://www.apache.org/licenses/LICENSE-2.0
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
14 """Contains RPC sequences to trigger specific issues through Netconf."""
16 # Test data for issue: https://jira.fd.io/browse/HONEYCOMB-105
17 # Creating and removing interfaces may result in duplicated interface indices.
19 <rpc message-id="m-1" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
24 <filter xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:type="subtree">
25 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
27 <name>4fe335c8-6fdc-4654-b12c-d256e9b39229</name>
35 <rpc message-id="m-2" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
44 <rpc message-id="m-3" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
49 <default-operation>none</default-operation>
51 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
52 <interface xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0"
53 a:operation="replace">
54 <name>4fe335c8-6fdc-4654-b12c-d256e9b39229</name>
55 <description>neutron port</description>
56 <link-up-down-trap-enable>enabled</link-up-down-trap-enable>
57 <vhost-user xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
59 <socket>/tmp/socket_4fe335c8-6fdc-4654-b12c-d256e9b39229</socket>
61 <type xmlns:x="urn:opendaylight:params:xml:ns:yang:v3po">x:vhost-user</type>
62 <enabled>true</enabled>
70 <rpc message-id="m-4" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
75 <rpc message-id="m-5" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
84 <rpc message-id="m-6" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
93 <rpc message-id="m-7" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
98 <default-operation>none</default-operation>
100 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
101 <interface xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0"
102 a:operation="delete">
103 <name>4fe335c8-6fdc-4654-b12c-d256e9b39229</name>
111 <rpc message-id="m-8" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
116 <rpc message-id="m-9" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
125 <rpc message-id="m-10" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
134 <rpc message-id="m-11" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
139 <default-operation>none</default-operation>
141 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
142 <interface xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0"
143 a:operation="replace">
144 <name>4fe335c8-6fdc-4654-b12c-d256e9b39229</name>
145 <description>neutron port</description>
146 <link-up-down-trap-enable>enabled</link-up-down-trap-enable>
147 <vhost-user xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
149 <socket>/tmp/socket_4fe335c8-6fdc-4654-b12c-d256e9b39229</socket>
151 <type xmlns:x="urn:opendaylight:params:xml:ns:yang:v3po">x:vhost-user</type>
152 <enabled>true</enabled>
160 <rpc message-id="m-12" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
165 <rpc message-id="m-13" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
174 <rpc message-id="m-14" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
183 <rpc message-id="m-15" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
188 <default-operation>none</default-operation>
190 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
191 <interface xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0"
192 a:operation="replace">
193 <name>d7611278-88ff-40e1-81e2-602e94e96fc7</name>
194 <description>neutron port</description>
195 <link-up-down-trap-enable>enabled</link-up-down-trap-enable>
196 <vhost-user xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
198 <socket>/tmp/socket_d7611278-88ff-40e1-81e2-602e94e96fc7</socket>
200 <type xmlns:x="urn:opendaylight:params:xml:ns:yang:v3po">x:vhost-user</type>
201 <enabled>true</enabled>
209 <rpc message-id="m-16" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
214 <rpc message-id="m-17" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
223 <rpc message-id="m-18" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
232 <rpc message-id="m-19" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
237 <default-operation>none</default-operation>
239 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
240 <interface xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0"
241 a:operation="replace">
242 <name>1f96a665-4351-4984-b1a8-dc6f54683123</name>
243 <description>neutron port</description>
244 <link-up-down-trap-enable>enabled</link-up-down-trap-enable>
245 <vhost-user xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
247 <socket>/tmp/socket_1f96a665-4351-4984-b1a8-dc6f54683123</socket>
249 <type xmlns:x="urn:opendaylight:params:xml:ns:yang:v3po">x:vhost-user</type>
250 <enabled>true</enabled>
258 <rpc message-id="m-20" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
263 <rpc message-id="m-21" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
272 <rpc message-id="m-22" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
281 <rpc message-id="m-23" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
286 <default-operation>none</default-operation>
288 <vpp xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
290 <bridge-domain xmlns:a="urn:ietf:params:xml:ns:netconf:base:1.0"
291 a:operation="replace">
292 <name>e86740a2-042c-4e64-a43b-cc224e0d5240</name>
293 <unknown-unicast-flood>true</unknown-unicast-flood>
294 <forward>true</forward>
297 <arp-termination>false</arp-termination>
306 <rpc message-id="m-24" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
311 <rpc message-id="m-25" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
320 <rpc message-id="m-26" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
329 <rpc message-id="m-27" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
331 <filter xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:type="subtree">
332 <interfaces-state xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces"/>
338 # Test data for issue: https://jira.fd.io/browse/HONEYCOMB-255
339 # Reverting transaction fails with "missing writer"
340 trigger_revert1 = u"""
341 <rpc message-id="101" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
347 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
350 <type xmlns:v3po="urn:opendaylight:params:xml:ns:yang:v3po">
351 v3po:vxlan-tunnel</type>
352 <enabled>true</enabled>
353 <vxlan xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
354 <src>192.168.1.6</src>
355 <dst>192.168.1.7</dst>
357 <encap-vrf-id>0</encap-vrf-id>
366 <rpc message-id="101" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
372 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
375 <type xmlns:v3po="urn:opendaylight:params:xml:ns:yang:v3po">
376 v3po:vxlan-tunnel</type>
377 <enabled>true</enabled>
378 <vxlan xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
379 <src>192.168.1.6</src>
380 <dst>192.168.1.7</dst>
382 <encap-vrf-id>0</encap-vrf-id>
391 <rpc message-id="102"
392 xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
397 # Test data for issue: https://jira.fd.io/browse/HONEYCOMB-255, part 2
398 # Reverting transaction fails with "transaction has been closed"
399 trigger_revert2 = u"""
400 <rpc message-id="101" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
406 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
409 <type xmlns:v3po="urn:opendaylight:params:xml:ns:yang:v3po">v3po:tap</type>
410 <enabled>true</enabled>
411 <tap xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
412 <tap-name>tap</tap-name>
421 <rpc message-id="101" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
427 <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
430 <type xmlns:v3po="urn:opendaylight:params:xml:ns:yang:v3po">v3po:tap</type>
431 <enabled>true</enabled>
432 <tap xmlns="urn:opendaylight:params:xml:ns:yang:v3po">
433 <tap-name>tap</tap-name>
442 <rpc message-id="102"
443 xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">