Reconfigure_ODL_To_Accept_Connection
[Documentation] Configure BGP peer module with initiate-connection set to false.
- ${template_as_string}= BuiltIn.Set_Variable {'IP': '${MININET}', 'HOLDTIME': '${HOLDTIME}', 'INITIATE': 'false'}
+ ${template_as_string}= BuiltIn.Set_Variable {'IP': '${MININET}', 'HOLDTIME': '${HOLDTIME}', 'PEER_PORT': '${BGP_TOOL_PORT}', 'INITIATE': 'false'}
ConfigViaRestconf.Put_Xml_Template_Folder_Config_Via_Restconf ${directory_with_template_folders}${/}bgp_peer ${template_as_string}
Start_Talking_BGP_speaker
[Documentation] Start Python speaker to connect to ODL, verify that the tool does not promptly exit.
# Myport value is needed for checking whether connection at precise port was established.
- # TODO: Do we want to define ${BGP_PORT} in Variables.py?
- BGPSpeaker.Start_BGP_Speaker --amount 2 --myip=${MININET} --myport=17900 --peerip=${CONTROLLER} --peerport=1790
+ BGPSpeaker.Start_BGP_Speaker --amount 2 --myip=${MININET} --myport=${BGP_TOOL_PORT} --peerip=${CONTROLLER} --peerport=${ODL_BGP_PORT}
Read_And_Fail_If_Prompt_Is_Seen
Check_Talking_Connection_Is_Established
Start_Listening_BGP_Speaker
[Documentation] Start Python speaker in listening mode, verify that the tool does not exit quickly.
- # TODO: ${BGP_TOOL_PORT} is probably not worth the trouble.
- BGPSpeaker.Start_BGP_Speaker --amount 2 --listen --myip=${MININET} --myport=17900 --peerip=${CONTROLLER}
+ BGPSpeaker.Start_BGP_Speaker --amount 2 --listen --myip=${MININET} --myport=${BGP_TOOL_PORT} --peerip=${CONTROLLER}
Read_And_Fail_If_Prompt_Is_Seen
Check_Listening_Connection_Is_Not_Established_Yet
Reconfigure_ODL_To_Initiate_Connection
[Documentation] Replace BGP peer config module, now with initiate-connection set to true.
- ${template_as_string}= BuiltIn.Set_Variable {'IP': '${MININET}', 'HOLDTIME': '${HOLDTIME}', 'INITIATE': 'true'}
+ ${template_as_string}= BuiltIn.Set_Variable {'IP': '${MININET}', 'HOLDTIME': '${HOLDTIME}', 'PEER_PORT': '${BGP_TOOL_PORT}', 'INITIATE': 'true'}
ConfigViaRestconf.Put_Xml_Template_Folder_Config_Via_Restconf ${directory_with_template_folders}${/}bgp_peer ${template_as_string}
Check_Listening_Connection_Is_Established
<type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">prefix:bgp-peer</type>
<name>example-bgp-peer</name>
<host xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">$IP</host>
- <port xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">17900</port>
+ <port xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">$PEER_PORT</port>
<holdtimer xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">$HOLDTIME</holdtimer>
<initiate-connection xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">$INITIATE</initiate-connection>
<rib xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:rib:impl">