Use RFC8040 URL for OVSDB tests 97/100497/7
authorSangwook Ha <sangwook.ha@verizon.com>
Sat, 9 Apr 2022 03:19:37 +0000 (20:19 -0700)
committerSangwook Ha <sangwook.ha@verizon.com>
Sat, 9 Apr 2022 17:24:01 +0000 (10:24 -0700)
Replace Bierman02 URLs in the OVSDB tests with RFC8040 URLs
using new variables defined for the paths commonly used for
the OVSDB CSIT tests. And also make changes in the status code
(204 for empty body) and the JSON data format (module prefix)
required for RFC8040.

Change-Id: I4634ab53fdc1f74b9a078c7f15a2fc8c40ebd7d4
Signed-off-by: Sangwook Ha <sangwook.ha@verizon.com>
15 files changed:
csit/libraries/ClusterManagement.robot
csit/libraries/ClusterOpenFlow.robot
csit/libraries/ClusterOvsdb.robot
csit/libraries/OVSDB.robot
csit/suites/genius/Service_Recovery.robot
csit/suites/ovsdb/Southbound_Domain/010__configure_1_ovsdb_node.robot
csit/suites/ovsdb/Southbound_Domain/020__connection_manager.robot
csit/suites/ovsdb/Southbound_Domain/030__configure_exit_ovsdb_node.robot
csit/suites/ovsdb/Southbound_Domain/040__Vxlan_Extension_Test.robot
csit/suites/ovsdb/Southbound_Domain/Bug_Validation.robot
csit/variables/ovsdb/Variables.robot [new file with mode: 0644]
csit/variables/ovsdb/create_bridge.json
csit/variables/ovsdb/create_bridge_3node.json
csit/variables/ovsdb/create_port.json
csit/variables/ovsdb/create_port_3node.json

index 4982cbb4a65c7316ce2252ce0e1489e16db384b3..e5ac43f38fd48e1edf0eb5f08dec1ec81fc3852b 100644 (file)
@@ -667,15 +667,6 @@ ClusterManagement__Clean_Directories
     END
 
 Put_As_Json_And_Check_Member_List_Or_All
-    [Arguments]    ${uri}    ${data}    ${member_index}    ${member_index_list}=${EMPTY}
-    [Documentation]    Send a PUT with the supplied uri ${uri} and body ${data} to member ${member_index}.
-    ...    Then check data is replicated in all or some members defined in ${member_index_list}.
-    ${response_text} =    Put_As_Json_To_Member    uri=${uri}    data=${data}    member_index=${member_index}
-    Wait Until Keyword Succeeds    5s    1s    Check_Json_Member_List_Or_All    uri=${uri}    expected_data=${data}    member_index_list=${member_index_list}
-    [Return]    ${response_text}
-
-Put_As_Json_And_Check_Member_List_Or_All_RFC8040
-    # FIXME: merge this keyword with Bierman02 version above when OVSDB test is migrated to RFC8040
     [Arguments]    ${uri}    ${data}    ${member_index}    ${member_index_list}=${EMPTY}
     [Documentation]    Send a PUT with the supplied uri ${uri} and body ${data} to member ${member_index}.
     ...    Then check data is replicated in all or some members defined in ${member_index_list}.
index 1291f2b8fdadefffe0fc20ad9cd7f8175e7ffa30..1560495d0790708ac4a4d8c4d5f782178fca4b50 100644 (file)
@@ -7,8 +7,8 @@ Resource          ClusterManagement.robot
 Resource          CompareStream.robot
 Resource          MininetKeywords.robot
 Resource          Utils.robot
-Variables         ../variables/Variables.py
 Resource          ../variables/openflowplugin/Variables.robot
+Variables         ../variables/Variables.py
 
 *** Variables ***
 @{SHARD_OPER_LIST}    inventory    topology    default    entity-ownership
@@ -80,7 +80,7 @@ Add Sample Flow And Verify
     # replicating some of the matches in the flows section. Same comment applies for further keywords.
     Run Keyword If    '${ODL_OF_PLUGIN}' == 'helium'    Set Test Variable    &{dictionary}    10.0.1.0/24=2    "output-node-connector":"1"=1
     Run Keyword If    '${ODL_OF_PLUGIN}' == 'lithium'    Set Test Variable    &{dictionary}    10.0.1.0/24=1    "output-node-connector":"1"=1
-    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All_RFC8040    ${config_table_0}/flow=1    ${body}    ${controller_index}    ${controller_index_list}
+    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${config_table_0}/flow=1    ${body}    ${controller_index}    ${controller_index_list}
     Wait Until Keyword Succeeds    15s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${operational_table_0}    dictionary=${dictionary}    member_index_list=${controller_index_list}
 
 Verify Sample Flow
@@ -98,7 +98,7 @@ Modify Sample Flow And Verify
     ${body}=    OperatingSystem.Get File    ${CURDIR}/../variables/openflowplugin/sample_flow_2.json
     Run Keyword If    '${ODL_OF_PLUGIN}' == 'helium'    Set Test Variable    &{dictionary}    10.0.1.0/24=2    "output-node-connector":"2"=1
     Run Keyword If    '${ODL_OF_PLUGIN}' == 'lithium'    Set Test Variable    &{dictionary}    10.0.1.0/24=1    "output-node-connector":"2"=1
-    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All_RFC8040    ${config_table_0}/flow=1    ${body}    ${controller_index}    ${controller_index_list}
+    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${config_table_0}/flow=1    ${body}    ${controller_index}    ${controller_index_list}
     Wait Until Keyword Succeeds    15s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${operational_table_0}    dictionary=${dictionary}    member_index_list=${controller_index_list}
 
 Delete Sample Flow And Verify
index ba40f0e6714c48718a27ddd018b445db1772ff79..41b95eed9fc052a77e7e439b71f36610782c638b 100644 (file)
@@ -7,6 +7,7 @@ Resource          CompareStream.robot
 Resource          MininetKeywords.robot
 Resource          Utils.robot
 Resource          OVSDB.robot
+Resource          ../variables/ovsdb/Variables.robot
 Variables         ../variables/Variables.py
 
 *** Variables ***
@@ -42,8 +43,8 @@ Create Sample Bridge Manually And Verify
     Utils.Run Command On Mininet    ${ovs_system_ip}    sudo ovs-vsctl add-br br-s1
     ${dictionary_operational}=    Create Dictionary    br-s1=5
     ${dictionary_config}=    Create Dictionary    br-s1=0
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${CONFIG_TOPO_API}    dictionary=${dictionary_config}    member_index_list=${controller_index_list}
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}    dictionary=${dictionary_operational}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_CONFIG_TOPO_API}    dictionary=${dictionary_config}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_OPERATIONAL_TOPO_API}    dictionary=${dictionary_operational}    member_index_list=${controller_index_list}
 
 Add Sample Port To The Manual Bridge And Verify
     [Arguments]    ${ovs_system_ip}=${TOOLS_SYSTEM_IP}    ${controller_index_list}=${EMPTY}
@@ -51,8 +52,8 @@ Add Sample Port To The Manual Bridge And Verify
     Utils.Run Command On Mininet    ${ovs_system_ip}    sudo ovs-vsctl add-port br-s1 vx1 -- set Interface vx1 type=vxlan
     ${dictionary_operational}=    Create Dictionary    vx1=2
     ${dictionary_config}=    Create Dictionary    vx1=0
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${CONFIG_TOPO_API}    dictionary=${dictionary_config}    member_index_list=${controller_index_list}
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}    dictionary=${dictionary_operational}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_CONFIG_TOPO_API}    dictionary=${dictionary_config}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_OPERATIONAL_TOPO_API}    dictionary=${dictionary_operational}    member_index_list=${controller_index_list}
 
 Create Sample Tap Device
     [Arguments]    ${ovs_system_ip}=${TOOLS_SYSTEM_IP}
@@ -68,15 +69,15 @@ Add Sample Tap Device To The Manual Bridge And Verify
     Utils.Run Command On Mininet    ${ovs_system_ip}    sudo ovs-vsctl add-port br-s1 vport1 -- add-port br-s1 vport2
     ${dictionary_operational}=    Create Dictionary    vport1=2    vport2=2
     ${dictionary_config}=    Create Dictionary    vport1=0    vport2=0
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${CONFIG_TOPO_API}    dictionary=${dictionary_config}    member_index_list=${controller_index_list}
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}    dictionary=${dictionary_operational}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_CONFIG_TOPO_API}    dictionary=${dictionary_config}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_OPERATIONAL_TOPO_API}    dictionary=${dictionary_operational}    member_index_list=${controller_index_list}
 
 Delete Sample Bridge Manually And Verify
     [Arguments]    ${ovs_system_ip}=${TOOLS_SYSTEM_IP}    ${controller_index_list}=${EMPTY}
     [Documentation]    Delete bridge br-s1 using OVS command and verify it gets applied in all instances in ${controller_index_list}.
     Utils.Run Command On Mininet    ${ovs_system_ip}    sudo ovs-vsctl del-br br-s1
     ${dictionary}=    Create Dictionary    br-s1=0
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}    dictionary=${dictionary}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_OPERATIONAL_TOPO_API}    dictionary=${dictionary}    member_index_list=${controller_index_list}
 
 Create Sample Bridge And Verify
     [Arguments]    ${controller_index}    ${controller_index_list}=${EMPTY}
@@ -92,9 +93,9 @@ Create Sample Bridge And Verify
     Log    ${body}
     ${TOOLS_SYSTEM_IP1}    Replace String    ${TOOLS_SYSTEM_IP}    ${TOOLS_SYSTEM_IP}    "${TOOLS_SYSTEM_IP}"
     ${dictionary}=    Create Dictionary    ${TOOLS_SYSTEM_IP1}=1    ${OVSDBPORT}=4    ${BRIDGE}=1
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}    ${body}    ${controller_index}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}    ${body}    ${controller_index}
     ...    ${controller_index_list}
-    Wait Until Keyword Succeeds    10s    2s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}    dictionary=${dictionary}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    10s    2s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}?${RFC8040_OPERATIONAL_CONTENT}    dictionary=${dictionary}    member_index_list=${controller_index_list}
 
 Create Sample Port And Verify
     [Arguments]    ${controller_index}    ${controller_index_list}=${EMPTY}
@@ -102,43 +103,43 @@ Create Sample Port And Verify
     ${sample}    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/create_port_3node.json
     ${body}    Replace String    ${sample}    192.168.1.10    ${TOOLS_SYSTEM_IP}
     Log    ${body}
-    Log    URL is ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point/vx2/
+    Log    URL is ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point=vx2
     ${port_dictionary}=    Create Dictionary    ${BRIDGE}=1    vx2=3
-    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point/vx2/    ${body}    ${controller_index}    ${controller_index_list}
-    Wait Until Keyword Succeeds    10s    2s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point/vx2/    dictionary=${port_dictionary}    member_index_list=${controller_index_list}
+    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point=vx2    ${body}    ${controller_index}    ${controller_index_list}
+    Wait Until Keyword Succeeds    10s    2s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point=vx2?${RFC8040_OPERATIONAL_CONTENT}    dictionary=${port_dictionary}    member_index_list=${controller_index_list}
 
 Modify the destination IP of Sample Port
     [Arguments]    ${controller_index}    ${controller_index_list}=${EMPTY}
     [Documentation]    Modify the dst ip of port vx2 in bridge ${BRIDGE} in controller ${controller_index}.
     ${sample}    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/create_port_3node.json
     ${body}    Replace String    ${sample}    192.168.1.10    10.0.0.19
-    Log    URL is ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point/vx2/
+    Log    URL is ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point=vx2
     Log    ${body}
-    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point/vx2/    ${body}    ${controller_index}    ${controller_index_list}
+    ClusterManagement.Put_As_Json_And_Check_Member_List_Or_All    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point=vx2    ${body}    ${controller_index}    ${controller_index_list}
 
 Verify Sample Port Is Modified
     [Arguments]    ${controller_index_list}=${EMPTY}
     [Documentation]    Verify dst ip of port vx2 in bridge ${BRIDGE} gets modified in all instances in ${controller_index_list}.
     ${port_dictionary}    Create Dictionary    br01=6    vx2=3    10.0.0.19=1
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}    dictionary=${port_dictionary}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}?${RFC8040_OPERATIONAL_CONTENT}    dictionary=${port_dictionary}    member_index_list=${controller_index_list}
 
 Delete Sample Port And Verify
     [Arguments]    ${controller_index}    ${controller_index_list}=${EMPTY}
     [Documentation]    Delete port vx2 from bridge ${BRIDGE} in controller ${controller_index} and verify it gets deleted in all instances in ${controller_index_list}.
     ${dictionary}=    Create Dictionary    vx2=0
-    ClusterManagement.Delete_And_Check_Member_List_Or_All    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point/vx2/    ${controller_index}    ${controller_index_list}
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}    dictionary=${dictionary}    member_index_list=${controller_index_list}
+    ClusterManagement.Delete_And_Check_Member_List_Or_All    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}/termination-point=vx2    ${controller_index}    ${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}?${RFC8040_OPERATIONAL_CONTENT}    dictionary=${dictionary}    member_index_list=${controller_index_list}
 
 Delete Sample Bridge And Verify
     [Arguments]    ${controller_index}    ${controller_index_list}=${EMPTY}
     [Documentation]    Delete bridge ${BRIDGE} in ${controller_index} and verify it gets deleted in all instances in ${controller_index_list}.
     ${dictionary}=    Create Dictionary    ${BRIDGE}=0
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Delete_And_Check_Member_List_Or_All    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}    ${controller_index}    ${controller_index_list}
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${ovsdb_uuid}    dictionary=${dictionary}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Delete_And_Check_Member_List_Or_All    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}%2Fbridge%2F${BRIDGE}    ${controller_index}    ${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${ovsdb_uuid}?${RFC8040_OPERATIONAL_CONTENT}    dictionary=${dictionary}    member_index_list=${controller_index_list}
 
 Configure Exit OVSDB Connection
     [Arguments]    ${controller_index_list}=${EMPTY}
     [Documentation]    Cleans up test environment, close existing sessions.
     OVSDB.Clean OVSDB Test Environment    ${TOOLS_SYSTEM_IP}
     ${dictionary}=    Create Dictionary    ovsdb://uuid=0
-    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${OPERATIONAL_TOPO_API}    dictionary=${dictionary}    member_index_list=${controller_index_list}
+    Wait Until Keyword Succeeds    5s    1s    ClusterManagement.Check_Item_Occurrence_Member_List_Or_All    uri=${RFC8040_OPERATIONAL_TOPO_API}    dictionary=${dictionary}    member_index_list=${controller_index_list}
index 39290747e3a9a0586d795e16e3b4aec8710787f7..be3d13b9755e4e9577e3cfd4abeb1ed13e7a0e1b 100644 (file)
@@ -9,13 +9,11 @@ Resource          ClusterManagement.robot
 Resource          Utils.robot
 Resource          ${CURDIR}/TemplatedRequests.robot
 Resource          ../variables/Variables.robot
+Resource          ../variables/ovsdb/Variables.robot
 Resource          ../variables/netvirt/Variables.robot
 
 *** Variables ***
 ${OVSDB_CONFIG_DIR}    ${CURDIR}/../variables/ovsdb
-${OVSDB_NODE_PORT}    6634
-${SOUTHBOUND_CONFIG_API}    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2F
-${SOUTHBOUND_NODE_CONFIG_API}    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2F${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}
 
 *** Keywords ***
 Log Request
@@ -30,7 +28,7 @@ Create OVSDB Node
     ${body} =    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/create_node.json
     ${body} =    Replace String    ${body}    127.0.0.1    ${node_ip}
     ${body} =    Replace String    ${body}    61644    ${port}
-    ${uri} =    Builtin.Set Variable    ${CONFIG_TOPO_API}/topology/ovsdb:1/
+    ${uri} =    Builtin.Set Variable    ${RFC8040_TOPO_OVSDB1_API}
     BuiltIn.Log    URI is ${uri}
     BuiltIn.Log    data: ${body}
     ${resp} =    RequestsLibrary.Post Request    session    ${uri}    data=${body}
@@ -43,7 +41,7 @@ Connect To Ovsdb Node
     ${body} =    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/connect.json
     ${body} =    String.Replace String    ${body}    127.0.0.1    ${node_ip}
     ${body} =    String.Replace String    ${body}    61644    ${port}
-    ${uri} =    BuiltIn.Set Variable    ${SOUTHBOUND_CONFIG_API}${node_ip}:${port}
+    ${uri} =    BuiltIn.Set Variable    ${RFC8040_SOUTHBOUND_NODE_API}${node_ip}%3A${port}
     BuiltIn.Log    URI is ${uri}
     BuiltIn.Log    data: ${body}
     ${resp} =    RequestsLibrary.Put Request    session    ${uri}    data=${body}
@@ -53,8 +51,8 @@ Connect To Ovsdb Node
 Disconnect From Ovsdb Node
     [Arguments]    ${node_ip}    ${port}=${OVSDB_NODE_PORT}
     [Documentation]    This request will disconnect the OVSDB node from the controller
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}${node_ip}:${port}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}${node_ip}%3A${port}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Add Bridge To Ovsdb Node
     [Arguments]    ${node_id}    ${node_ip}    ${bridge}    ${datapath_id}    ${port}=${OVSDB_NODE_PORT}
@@ -66,8 +64,8 @@ Add Bridge To Ovsdb Node
     ${body} =    String.Replace String    ${body}    br01    ${bridge}
     ${body} =    String.Replace String    ${body}    61644    ${port}
     ${body} =    String.Replace String    ${body}    0000000000000001    ${datapath_id}
-    ${node_id_} =    BuiltIn.Evaluate    """${node_id}""".replace("/","%2F")
-    ${uri} =    BuiltIn.Set Variable    ${SOUTHBOUND_CONFIG_API}${node_id_}%2Fbridge%2F${bridge}
+    ${node_id_} =    BuiltIn.Evaluate    """${node_id}""".replace("/","%2F").replace(":","%3A")
+    ${uri} =    BuiltIn.Set Variable    ${RFC8040_SOUTHBOUND_NODE_API}${node_id_}%2Fbridge%2F${bridge}
     BuiltIn.Log    URI is ${uri}
     BuiltIn.Log    data: ${body}
     ${resp} =    RequestsLibrary.Put Request    session    ${uri}    data=${body}
@@ -77,8 +75,8 @@ Add Bridge To Ovsdb Node
 Delete Bridge From Ovsdb Node
     [Arguments]    ${node_id}    ${bridge}
     [Documentation]    This request will delete the bridge node from the OVSDB
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}${node_id}%2Fbridge%2F${bridge}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}${node_id}%2Fbridge%2F${bridge}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Add Termination Point
     [Arguments]    ${node_id}    ${bridge}    ${tp_name}    ${remote_ip}=${TOOLS_SYSTEM_IP}
@@ -88,9 +86,9 @@ Add Termination Point
     ${body} =    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/create_port.json
     ${body} =    String.Replace String    ${body}    192.168.0.21    ${remote_ip}
     ${body} =    String.Replace String    ${body}    vxlanport    ${tp_name}
-    ${node_id_} =    BuiltIn.Evaluate    """${node_id}""".replace("/","%2F")
-    ${uri} =    BuiltIn.Set Variable    ${SOUTHBOUND_CONFIG_API}${node_id_}%2Fbridge%2F${bridge}
-    ${resp} =    RequestsLibrary.Put Request    session    ${uri}/termination-point/${tp_name}/    data=${body}
+    ${node_id_} =    BuiltIn.Evaluate    """${node_id}""".replace("/","%2F").replace(":","%3A")
+    ${uri} =    BuiltIn.Set Variable    ${RFC8040_SOUTHBOUND_NODE_API}${node_id_}%2Fbridge%2F${bridge}
+    ${resp} =    RequestsLibrary.Put Request    session    ${uri}/termination-point=${tp_name}    data=${body}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
 
 Add Vxlan To Bridge
@@ -121,11 +119,11 @@ Get OVSDB UUID
     ...    the ${ovs_system_ip} argument as the "remote-ip". If found, the value returned will be the value of
     ...    node-id stripped of "ovsdb://uuid/". If not found, ${EMPTY} will be returned.
     ${uuid} =    Set Variable    ${EMPTY}
-    ${resp} =    RequestsLibrary.Get Request    ${controller_http_session}    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1
+    ${resp} =    RequestsLibrary.Get Request    ${controller_http_session}    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     ${resp_json} =    RequestsLibrary.To Json    ${resp.text}
-    ${topologies} =    Collections.Get From Dictionary    ${resp_json}    topology
+    ${topologies} =    Collections.Get From Dictionary    ${resp_json}    network-topology:topology
     ${topology} =    Collections.Get From List    ${topologies}    0
     ${node_list} =    Collections.Get From Dictionary    ${topology}    node
     BuiltIn.Log    ${node_list}
@@ -247,16 +245,16 @@ Get Port Metadata
 
 Log Config And Operational Topology
     [Documentation]    For debugging purposes, this will log both config and operational topo data stores
-    ${resp}    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp}    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
-    ${resp} =    RequestsLibrary.Get Request    session    ${OPERATIONAL_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_OPERATIONAL_TOPO_API}
     OVSDB.Log Request    ${resp.text}
 
 Config and Operational Topology Should Be Empty
     [Documentation]    This will check that only the expected output is there for both operational and config
     ...    topology data stores. Empty probably means that only ovsdb:1 is there.
-    ${config_resp}    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
-    ${operational_resp}    RequestsLibrary.Get Request    session    ${OPERATIONAL_TOPO_API}
+    ${config_resp}    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
+    ${operational_resp}    RequestsLibrary.Get Request    session    ${RFC8040_OPERATIONAL_TOPO_API}
     BuiltIn.Should Contain    ${config_resp.text}    {"topology-id":"ovsdb:1"}
     BuiltIn.Should Contain    ${operational_resp.text}    {"topology-id":"ovsdb:1"}
 
@@ -274,7 +272,7 @@ Modify Multi Port Body
     ${body} =    Replace String    ${body}    OVS_2_IP    ${TOOLS_SYSTEM_2_IP}
     ${body} =    Replace String    ${body}    OVS_1_PORT_NAME    ${ovs_1_port_name}
     ${body} =    Replace String    ${body}    OVS_2_PORT_NAME    ${ovs_2_port_name}
-    ${uri} =    Builtin.Set Variable    ${CONFIG_TOPO_API}
+    ${uri} =    Builtin.Set Variable    ${RFC8040_TOPO_API}
     BuiltIn.Log    URI is ${uri}
     BuiltIn.Log    data: ${body}
     ${resp} =    RequestsLibrary.Put Request    session    ${uri}    data=${body}
@@ -285,7 +283,7 @@ Modify Multi Port Body
 Create Qos
     [Arguments]    ${qos}
     ${body} =    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/create_qos.json
-    ${uri} =    BuiltIn.Set Variable    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:qos-entries/${qos}/
+    ${uri} =    BuiltIn.Set Variable    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:qos-entries=${qos}
     ${body} =    Replace String    ${body}    QOS-1    ${qos}
     BuiltIn.Log    URI is ${uri}
     BuiltIn.Log    data: ${body}
@@ -297,7 +295,7 @@ Create Queue
     [Arguments]    ${queue}
     ${body} =    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/create_qoslinkedqueue.json
     ${body} =    Replace String    ${body}    QUEUE-1    ${queue}
-    ${uri} =    BuiltIn.Set Variable    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:queues/${queue}/
+    ${uri} =    BuiltIn.Set Variable    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:queues=${queue}
     BuiltIn.Log    URI is ${uri}
     BuiltIn.Log    data: ${body}
     ${resp} =    RequestsLibrary.Put Request    session    ${uri}    data=${body}
@@ -307,7 +305,7 @@ Create Queue
 Update Qos
     [Arguments]    ${qos}
     ${body} =    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/update_existingqos.json
-    ${uri} =    BuiltIn.Set Variable    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:qos-entries/${QOS}/
+    ${uri} =    BuiltIn.Set Variable    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:qos-entries=${QOS}
     BuiltIn.Log    URL is ${uri}
     BuiltIn.Log    data: ${body}
     ${resp} =    RequestsLibrary.Put Request    session    ${uri}    data=${body}
@@ -316,7 +314,7 @@ Update Qos
 
 Create Qos Linked Queue
     ${body}    OperatingSystem.Get File    ${OVSDB_CONFIG_DIR}/bug_7160/create_qoslinkedqueue.json
-    ${resp}    RequestsLibrary.Put Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1    data=${body}
+    ${resp}    RequestsLibrary.Put Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}    data=${body}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
 
@@ -350,7 +348,7 @@ Suite Teardown
     FOR    ${uri}    IN    @{uris}
         RequestsLibrary.Delete Request    session    ${uri}
     END
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Config And Operational Topology
     RequestsLibrary.Delete All Sessions
 
index 6261f77cb9d408119dc228bf0063951c3dd9ce11..52aa8706eaf0cdbc1cf88d8ed187dd7901417fa5 100644 (file)
@@ -49,7 +49,7 @@ IFM Service Recovery
     ...    odl-interface:tunnel-type-vxlan
     SSHLibrary.Switch Connection    ${TOOLS_SYSTEM_ALL_CONN_IDS[0]}
     ${uuid}    ${bridge} =    OVSDB.Get Bridge Data
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}uuid%2F${uuid}%2Fbridge%2F${bridge}
+    ${resp} =    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${uuid}%2Fbridge%2F${bridge}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    ${RESP_CODE}
     BuiltIn.Wait Until Keyword Succeeds    60s    5s    Genius.Verify Tunnel Delete on DS    ${tunnel}
     KarafKeywords.Issue Command On Karaf Console    srm:recover SERVICE IFM
index acf9ca17fadc3e0c24aaa3ef3c15c724e8e9cd89..8dc90d6fad4a2b690dd0ef1448c06dff7f6dd89e 100644 (file)
@@ -10,6 +10,7 @@ Resource          ../../../libraries/OVSDB.robot
 Resource          ../../../libraries/SetupUtils.robot
 Resource          ../../../libraries/Utils.robot
 Resource          ../../../variables/Variables.robot
+Resource          ../../../variables/ovsdb/Variables.robot
 
 *** Variables ***
 ${BRIDGE}         ovsconf_br
@@ -30,7 +31,7 @@ Connect to OVSDB Node
 
 Get Operational Topology
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${NODE_LIST}    pretty_print_json=True
 
 Create a Bridge
     [Documentation]    This will create bridge on the specified OVSDB node.
@@ -38,7 +39,7 @@ Create a Bridge
 
 Get Config Topology with Bridge
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the bridge is added to the data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     BuiltIn.Should Contain    ${resp.text}    ${BRIDGE}
@@ -46,7 +47,7 @@ Get Config Topology with Bridge
 Get Operational Topology with Bridge
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes to verify the bridge is added to the data store
     @{list} =    BuiltIn.Create List    ${BRIDGE}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Create Port and Attach to a Bridge
     [Documentation]    This request will creates port/interface and attach it to the specific bridge
@@ -55,49 +56,49 @@ Create Port and Attach to a Bridge
 Get Operational Topology with Port
     [Documentation]    This request will fetch the operational topology after the Port is added to the bridge
     @{list} =    BuiltIn.Create List    ${BRIDGE}    ${PORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Delete the Port
     [Documentation]    This request will delete the port node from the bridge node and data store.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}%2Fbridge%2F${BRIDGE}/termination-point/${PORT}/
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${BRIDGE}/termination-point=${PORT}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after Deletion of Port
     [Documentation]    This request will fetch the operational topology after the Port is deleted
     @{list} =    BuiltIn.Create List    ${PORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Delete the Bridge
     [Documentation]    This request will delete the bridge node from the config data store.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}%2Fbridge%2F${BRIDGE}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${BRIDGE}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after Deletion of Bridge
     [Documentation]    This request will fetch the operational topology after the Bridge is deleted
     @{list} =    BuiltIn.Create List    ${BRIDGE}    ${PORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Verify Config Still Has OVS Info
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the node is still in the data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${NODE_LIST}    pretty_print_json=True
 
 Delete the OVSDB Node
     [Documentation]    This request will delete the OVSDB node
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology to make sure the connection has been deleted
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
     @{list} =    BuiltIn.Create List    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Get Configuration Topology to make sure the connection has been deleted
     [Documentation]    This request will fetch the configuration topology from the connected OVSDB nodes
     @{list} =    BuiltIn.Create List    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${CONFIG_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_CONFIG_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Reconnect to OVSDB Node
     [Documentation]    Initiate the connection to OVSDB node from controller
@@ -105,14 +106,14 @@ Reconnect to OVSDB Node
 
 Get Operational Topology After Node Reconnect
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes to verify the bridge is added to the data store
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${NODE_LIST}    pretty_print_json=True
 
 Get Config Topology After Reconnect
     [Documentation]    This will fetch the configuration topology from configuration data store after reconnect
-    ${resp}    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp}    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${NODE_LIST}    pretty_print_json=True
 
 Create OVSDB NODE HOST1
     [Documentation]    This request will create OVSDB NODE HOST1
@@ -136,7 +137,7 @@ Update QOS with a Linked queue entry to a OVSDB Node
 
 Get QOS Config Topology with port
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the QOS is added to the data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
     BuiltIn.Should Contain    ${resp.text}    ${QOS}
@@ -144,11 +145,11 @@ Get QOS Config Topology with port
 Get QOS Operational Topology with port
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes to verify the QOS is added to the data store
     @{list} =    BuiltIn.Create List    ${QOS}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Get Queue Config Topology with port
     [Documentation]    This request will fetch the configuration topology from configuration data store to verify the Queue is added to the data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
     BuiltIn.Should Contain    ${resp.text}    ${QUEUE}
@@ -156,31 +157,31 @@ Get Queue Config Topology with port
 Get Queue Operational Topology with port
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes to verify the Queue is added to the data store
     @{list} =    BuiltIn.Create List    ${QUEUE}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Delete a Queue entry from a Qos entry
     [Documentation]    This request will Delete a Queue entry from a Qos entry
-    ${resp} =    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:qos-entries/${QOS}/queue-list/0/
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:qos-entries=${QOS}/queue-list=0
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
 
 Delete a QoS entry from a node
     [Documentation]    This request will Delete a QoS entry from a node.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:qos-entries/${QOS}/
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:qos-entries=${QOS}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
 
 Delete a Queue entry from an ovsdb node
     [Documentation]    This request will Delete a Queue entry from an ovsdb node
-    ${resp} =    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:queues/${QUEUE}/
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:queues=${QUEUE}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
 
 Delete the OVSDB Node HOST1
     [Documentation]    This request will delete the OVSDB node
-    ${resp} =    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
 
 Get Config Topology to verify that deleted configurations are cleaned from config datastore
     [Documentation]    This request will fetch the configuration topology from configuration data store to verify OVSDB NODE is deleted frrom the configuration data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Contain    ${ALLOWED_STATUS_CODES}    ${resp.status_code}
     BuiltIn.Should Not Contain    ${resp.text}    ovsdb:HOST1
@@ -200,5 +201,5 @@ Check For Bug 4794
 *** Keywords ***
 Suite Teardown
     [Documentation]    Cleans up test environment, close existing sessions.
-    @{uris} =    Builtin.Create List    ${SOUTHBOUND_NODE_CONFIG_API}
+    @{uris} =    Builtin.Create List    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
     OVSDB.Suite Teardown    ${uris}
index 9647f69b0bb3be2396084ae4bdcfaf640d13a266..301f8a7711ce72cc7fc0753979f6a2c4629cbf31 100644 (file)
@@ -9,6 +9,7 @@ Resource          ../../../libraries/SetupUtils.robot
 Resource          ../../../libraries/Utils.robot
 Resource          ../../../libraries/OVSDB.robot
 Resource          ../../../variables/Variables.robot
+Resource          ../../../variables/ovsdb/Variables.robot
 
 *** Variables ***
 ${BRIDGE1}        ovscon_br1
@@ -25,13 +26,13 @@ Connecting an OVS instance to the controller
 Get Operational Topology to verify the ovs instance is connected to the controller
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
     @{list} =    BuiltIn.Create List    ovsdb://uuid    "remote-ip":"${TOOLS_SYSTEM_IP}"    "local-port":${OVSDBPORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     ${OVSDB_UUID} =    OVSDB.Get OVSDB UUID    ${TOOLS_SYSTEM_IP}
     BuiltIn.Set Suite Variable    ${OVSDB_UUID}
 
 Verify OVS Not In Config Topology
     [Documentation]    This request will fetch the configuration topology from configuration data store
-    Utils.Check For Elements Not At URI    ${CONFIG_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
+    Utils.Check For Elements Not At URI    ${RFC8040_CONFIG_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
 
 Create bridge manually
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl add-br ${BRIDGE1}
@@ -39,11 +40,11 @@ Create bridge manually
 Get Operational Topology to verify the bridge has been added
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
     @{list} =    BuiltIn.Create List    ${BRIDGE1}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Get Config Topology to verify the manually added bridge is not added to the config datastore
     [Documentation]    This request will fetch the configuration topology from configuration data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     BuiltIn.Should Not Contain    ${resp.text}    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}/bridge/${BRIDGE1}
@@ -55,11 +56,11 @@ Create a Bridge through controller
 Get Operational Topology to verify the bridge has been added through rest call
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
     @{list} =    BuiltIn.Create List    ${BRIDGE2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Get Config Topology to verify the entry added to the config datastore
     [Documentation]    This request will fetch the configuration topology from configuration data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     BuiltIn.Should Contain    ${resp.text}    ovsdb://uuid/${OVSDB_UUID}/bridge/${BRIDGE2}
@@ -70,7 +71,7 @@ Create bridge of already added bridge
 
 Get Config Topology to verify the entry of existing bridge added to the config datastore
     [Documentation]    This request will fetch the configuration topology from configuration data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     BuiltIn.Should Contain    ${resp.text}    ovsdb://uuid/${OVSDB_UUID}/bridge/${BRIDGE1}
@@ -81,24 +82,24 @@ Delete bridge manually
 Get Operational Topology to verify the bridge has been deleted manually
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
     @{list} =    BuiltIn.Create List    ${BRIDGE2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Config Topology Still Contains Bridge
     [Documentation]    This request will fetch the configuration topology from configuration data store
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     BuiltIn.Should Contain    ${resp.text}    ovsdb://uuid/${OVSDB_UUID}/bridge/${BRIDGE2}
 
 Delete the Bridge through rest call
     [Documentation]    This request will delete the bridge node from the config data store.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE2}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE2}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after Deletion of Bridge
     [Documentation]    This request will fetch the operational topology after the Bridge is deleted
     @{list} =    BuiltIn.Create List    ${BRIDGE2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
 
 Trunk And Vlan Tag Is Removed From Operational
     [Documentation]    Verify that when the vlan tag is added and removed from an ovs port, it should be accurately reflected
@@ -113,16 +114,16 @@ Trunk And Vlan Tag Is Removed From Operational
     BuiltIn.Wait Until Keyword Succeeds    5s    1s    OVSDB.Verify OVS Reports Connected
     OVSDB.Collect OVSDB Debugs
     @{list}    BuiltIn.Create List    vlan-tag-br    vlan-tag-port    "ovsdb:vlan-tag":81    "trunk":181    "trunk":182
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl clear port vlan-tag-port tag
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl remove port vlan-tag-port trunks 181
     @{list}    BuiltIn.Create List    "ovsdb:vlan-tag":81    "trunk":181
     OVSDB.Collect OVSDB Debugs
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl clear port vlan-tag-port trunks
     @{list}    BuiltIn.Create List    "ovsdb:vlan-tag":81    "trunk":181    "trunk":182
     OVSDB.Collect OVSDB Debugs
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     [Teardown]    Builtin.Run Keywords    Clean OVSDB Test Environment    ${TOOLS_SYSTEM_IP}
     ...    AND    Utils.Report_Failure_Due_To_Bug    OVSDB-413
 
@@ -141,5 +142,5 @@ Check For Bug 4794
 *** Keywords ***
 Suite Teardown
     [Documentation]    Cleans up test environment, close existing sessions.
-    @{uris} =    Builtin.Create List    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE1}    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2Fuuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE2}
+    @{uris} =    Builtin.Create List    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE1}    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE2}
     OVSDB.Suite Teardown    ${uris}
index 3ff439696db46d82880970fcd7c87be14a057c9b..dd653680201fde31315a703346e6154e057a5e04 100644 (file)
@@ -9,6 +9,7 @@ Resource          ../../../libraries/OVSDB.robot
 Resource          ../../../libraries/SetupUtils.robot
 Resource          ../../../libraries/Utils.robot
 Resource          ../../../variables/Variables.robot
+Resource          ../../../variables/ovsdb/Variables.robot
 
 *** Variables ***
 ${BRIDGE}         ovsconf_exit_br
@@ -30,13 +31,13 @@ Connect to OVSDB Node
 
 Get Operational Topology
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
     [Teardown]    Utils.Report_Failure_Due_To_Bug    5221
 
 Verify Bridge Port Not In Config DS
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the bridge is added to the data store
     @{list} =    BuiltIn.Create List    ${PORT1}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${CONFIG_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_CONFIG_TOPO_API}    ${list}    pretty_print_json=True
 
 Create bridge of already added bridge
     [Documentation]    This will add bridge to the config datastore
@@ -45,7 +46,7 @@ Create bridge of already added bridge
 Get Config Topology with Bridge
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the bridge is added to the data store
     @{list} =    BuiltIn.Create List    ${BRIDGE}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${CONFIG_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_CONFIG_TOPO_API}    ${list}    pretty_print_json=True
 
 Create Port of already added port in OVSDB
     [Documentation]    This will add port/interface to the config datastore
@@ -53,7 +54,7 @@ Create Port of already added port in OVSDB
 
 Get Config Topology with Bridge and Port
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the bridge is added to the data store
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${CONFIG_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_CONFIG_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
 
 Modify the destination IP of Port
     [Documentation]    This will modify the dst ip of existing port
@@ -62,7 +63,7 @@ Modify the destination IP of Port
 Get Operational Topology with modified Port
     [Documentation]    This request will fetch the operational topology after the Port is added to the bridge
     @{list} =    BuiltIn.Create List    ${BRIDGE}    ${PORT1}    10.0.0.19
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
     [Teardown]    Utils.Report_Failure_Due_To_Bug    5221
 
 Create Port and attach to a Bridge
@@ -72,48 +73,48 @@ Create Port and attach to a Bridge
 Get Operational Topology with Port
     [Documentation]    This request will fetch the operational topology after the Port is added to the bridge
     @{list} =    BuiltIn.Create List    ${BRIDGE}    ${PORT2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
     [Teardown]    Utils.Report_Failure_Due_To_Bug    5221
 
 Delete the Port1
     [Documentation]    This request will delete the port node from the bridge node and data store.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}%2Fbridge%2F${BRIDGE}/termination-point/${PORT1}/
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${BRIDGE}/termination-point=${PORT1}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after deletion of Port1
     [Documentation]    This request will fetch the operational topology after the Port is added to the bridge
     @{list} =    BuiltIn.Create List    ${PORT1}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Delete the Port2
     [Documentation]    This request will delete the port node from the bridge node and data store.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}%2Fbridge%2F${BRIDGE}/termination-point/${PORT2}/
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${BRIDGE}/termination-point=${PORT2}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after Deletion of Port2
     [Documentation]    This request will fetch the operational topology after the Port is deleted
     @{list} =    BuiltIn.Create List    ${PORT2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Delete the Bridge
     [Documentation]    This request will delete the bridge node from the config data store.
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}%2Fbridge%2F${BRIDGE}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${BRIDGE}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after Deletion of Bridge
     [Documentation]    This request will fetch the operational topology after the Bridge is deleted
     @{list} =    BuiltIn.Create List    ${BRIDGE}    ${PORT1}    ${PORT2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Delete the OVSDB Node
     [Documentation]    This request will delete the OVSDB node
-    ${resp} =    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_NODE_CONFIG_API}
-    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
+    ${resp} =    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
+    BuiltIn.Should Be Equal As Strings    ${resp.status_code}    204
 
 Get Operational Topology after Deletion of OVSDB Node
     [Documentation]    This request will fetch the operational topology after the OVSDB node is deleted
     @{list} =    BuiltIn.Create List    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}    ${BRIDGE}    ${PORT1}    ${PORT2}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Check For Bug 4756
     [Documentation]    bug 4756 has been seen in the OVSDB Southbound suites. This test case should be one of the last test
@@ -130,5 +131,5 @@ Check For Bug 4794
 *** Keywords ***
 Suite Teardown
     [Documentation]    Cleans up test environment, close existing sessions.
-    @{uris} =    Builtin.Create List    ${SOUTHBOUND_NODE_CONFIG_API}
+    @{uris} =    Builtin.Create List    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
     OVSDB.Suite Teardown    ${uris}
index 24f5575fef5363d50e1554edbe0bea82f2603050..95d3dd4e0f351c643eec10768d665d09ce4436cd 100644 (file)
@@ -10,6 +10,7 @@ Resource          ../../../libraries/OVSDB.robot
 Resource          ../../../libraries/SetupUtils.robot
 Resource          ../../../libraries/Utils.robot
 Resource          ../../../variables/Variables.robot
+Resource          ../../../variables/ovsdb/Variables.robot
 
 *** Variables ***
 @{NODE_LIST}      ${OVSDB_NODE_PORT}    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}    ${TOOLS_SYSTEM_IP}    ${OVSDB_NODE_PORT}    ovsdb://${TOOLS_SYSTEM_2_IP}:${OVSDB_NODE_PORT}    ${TOOLS_SYSTEM_2_IP}
@@ -33,7 +34,7 @@ Connect controller to OVSDB Node2
 
 Get Operational Topology from OVSDB Node1 and OVSDB Node2
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${NODE_LIST}    pretty_print_json=True
 
 Start the Mininet and create custom topology
     [Documentation]    This will start mininet with custom topology on both the Virtual Machines
@@ -43,7 +44,7 @@ Start the Mininet and create custom topology
 Get Operational Topology with custom topology
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes to make sure the mininet created custom topology
     @{list} =    BuiltIn.Create List    s1    s2
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Add the bridge s1 in the config datastore of OVSDB Node1
     [Documentation]    This request will add already operational bridge to the config data store of the OVSDB node.
@@ -56,7 +57,7 @@ Add the bridge s2 in the config datastore of OVSDB Node2
 Get Config Topology with s1 and s2 Bridges
     [Documentation]    This will fetch the configuration topology from configuration data store to verify the bridge is added to the config data store
     @{list} =    BuiltIn.Create List    s1    s2
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${CONFIG_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_CONFIG_TOPO_API}    ${list}    pretty_print_json=True
 
 Create Vxlan Port and attach to s1 Bridge
     [Documentation]    This request will create vxlan port/interface for vxlan tunnel and attach it to the specific bridge s1 of OVSDB node 1
@@ -69,7 +70,7 @@ Create Vxlan Port and attach to s2 Bridge
 Get Operational Topology with vxlan tunnel
     [Documentation]    This request will fetch the operational topology from the connected OVSDB nodes to verify that the vxlan tunnel is created
     @{list} =    BuiltIn.Create List    s1-s2    s2-s1    ${TOOLS_SYSTEM_IP}    ${TOOLS_SYSTEM_2_IP}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Delete Bridges from config datastore
     [Documentation]    This request will delete the bridges from config data store.
@@ -87,7 +88,7 @@ Verify that the operational topology is clean
     [Documentation]    This request will verify the operational toplogy after the mininet is cleaned.
     [Tags]    Southbound
     @{list} =    BuiltIn.Create List    ${TOOLS_SYSTEM_IP}    ${TOOLS_SYSTEM_2_IP}    s1    s2
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_API}    ${list}    pretty_print_json=True
 
 Check For Bug 4756
     [Documentation]    bug 4756 has been seen in the OVSDB Southbound suites. This test case should be one of the last test
@@ -106,6 +107,6 @@ Suite Teardown
     [Documentation]    Cleans up test environment, close existing sessions.
     OVSDB.Clean OVSDB Test Environment    ${TOOLS_SYSTEM_IP}
     OVSDB.Clean OVSDB Test Environment    ${TOOLS_SYSTEM_2_IP}
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Config And Operational Topology
     RequestsLibrary.Delete All Sessions
index fdd97691889a8848b8f3f0fb7d4541d044fd96c4..ba5c24297562ed96029fa45f44d60b1520c7d5af 100644 (file)
@@ -20,6 +20,7 @@ Resource          ../../../libraries/SetupUtils.robot
 Resource          ../../../libraries/Utils.robot
 Resource          ../../../libraries/WaitForFailure.robot
 Resource          ../../../variables/Variables.robot
+Resource          ../../../variables/ovsdb/Variables.robot
 
 *** Variables ***
 ${BRIDGE}         ovsbug_br
@@ -48,7 +49,7 @@ Bug 7414 Same Endpoint Name
     BuiltIn.Wait Until Keyword Succeeds    60s    10s    Verify TEP Creation on OVS    ${TOOLS_SYSTEM_IP}    ${TOOLS_SYSTEM_2_IP}
     BuiltIn.Wait Until Keyword Succeeds    60s    10s    Verify TEP Creation on OVS    ${TOOLS_SYSTEM_2_IP}    ${TOOLS_SYSTEM_IP}
     [Teardown]    BuiltIn.Run Keywords    Test Teardown
-    ...    AND    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}    data=${body}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_TOPO_API}    data=${body}
 
 Bug 7414 Different Endpoint Name
     [Documentation]    This test case is supplemental to the other test case for bug 7414. Even when the other
@@ -74,7 +75,7 @@ Bug 7414 Different Endpoint Name
     BuiltIn.Wait Until Keyword Succeeds    60s    10s    Verify TEP Creation on OVS    ${TOOLS_SYSTEM_IP}    ${TOOLS_SYSTEM_2_IP}
     BuiltIn.Wait Until Keyword Succeeds    60s    10s    Verify TEP Creation on OVS    ${TOOLS_SYSTEM_2_IP}    ${TOOLS_SYSTEM_IP}
     [Teardown]    BuiltIn.Run Keywords    Test Teardown
-    ...    AND    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}    data=${body}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_TOPO_API}    data=${body}
 
 Bug 5221
     [Documentation]    In the case that an ovs node is rebooted, or the ovs service is
@@ -86,18 +87,18 @@ Bug 5221
     OVSDB.Connect To OVSDB Node    ${TOOLS_SYSTEM_IP}
     BuiltIn.Wait Until Keyword Succeeds    5s    1s    OVSDB.Verify OVS Reports Connected
     @{list} =    BuiltIn.Create List    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     OVSDB.Add Bridge To Ovsdb Node    ${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}    ${TOOLS_SYSTEM_IP}    ${bridge}    0000000000005221
     @{list} =    BuiltIn.Create List    ovsdb://${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}/bridge/${bridge}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo /usr/share/openvswitch/scripts/ovs-ctl stop
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements Not At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo /usr/share/openvswitch/scripts/ovs-ctl start
     # Depending on when the retry timers are firing, it may take some 10s of seconds to reconnect, so setting to 30 to cover that.
-    BuiltIn.Wait Until Keyword Succeeds    30s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    30s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     [Teardown]    BuiltIn.Run Keywords    Test Teardown
-    ...    AND    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2F${TOOLS_SYSTEM_IP}:6634%2Fbridge%2F${bridge}
-    ...    AND    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:%2F%2F${TOOLS_SYSTEM_IP}:6634
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${bridge}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
 
 Bug 5177
     [Documentation]    This test case will recreate the bug using the same basic steps as
@@ -114,13 +115,13 @@ Bug 5177
     BuiltIn.Set Suite Variable    ${OVSDB_UUID}
     ${node} =    BuiltIn.Set Variable    uuid/${OVSDB_UUID}
     OVSDB.Add Bridge To Ovsdb Node    ${node}    ${TOOLS_SYSTEM_IP}    ${BRIDGE}    0000000000005177
-    ${resp} =    RequestsLibrary.Get Request    session    ${CONFIG_TOPO_API}
+    ${resp} =    RequestsLibrary.Get Request    session    ${RFC8040_CONFIG_TOPO_API}
     OVSDB.Log Request    ${resp.text}
     BuiltIn.Should Be Equal As Strings    ${resp.status_code}    200
     BuiltIn.Should Contain    ${resp.text}    ${node}/bridge/${BRIDGE}
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl set-manager tcp:${ODL_SYSTEM_IP}:${OVSDBPORT}
     @{list} =    BuiltIn.Create List    ${BRIDGE}
-    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${OPERATIONAL_TOPO_API}/topology/ovsdb:1    ${list}    pretty_print_json=True
+    BuiltIn.Wait Until Keyword Succeeds    8s    2s    Utils.Check For Elements At URI    ${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${list}    pretty_print_json=True
     # Do not cleanup as the next test requires the steps done in this test
     [Teardown]    BuiltIn.Run Keywords    Utils.Report_Failure_Due_To_Bug    5177
     ...    AND    OVSDB.Log Config And Operational Topology
@@ -139,8 +140,8 @@ Bug 4794
     Verify_Keyword_Does_Not_Fail_Within_Timeout    10s    1s    Utils.Check Karaf Log File Does Not Have Messages    ${ODL_SYSTEM_IP}    Shard.*shard-topology-operational An exception occurred while preCommitting transaction
     # TODO: Bug 5178
     [Teardown]    BuiltIn.Run Keywords    Test Teardown
-    ...    AND    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}${node_id}%2Fbridge%2F${BRIDGE}
-    ...    AND    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}${node_id}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}${node_id}%2Fbridge%2F${BRIDGE}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}${node_id}
 
 Bug 8280
     [Documentation]    Any config created for a bridge (e.g. added ports) should be reconciled when a bridge is
@@ -157,7 +158,7 @@ Bug 8280
     OVSDB.Add Termination Point    uuid/${OVSDB_UUID2}    ${BRIDGE}    port1
     OVSDB.Add Termination Point    uuid/${OVSDB_UUID2}    ${BRIDGE}    port2
     ${config_store_elements} =    BuiltIn.Create List    ${BRIDGE}    port1    port2
-    Utils.Check For Elements At URI    ${CONFIG_TOPO_API}    ${config_store_elements}    pretty_print_json=True
+    Utils.Check For Elements At URI    ${RFC8040_CONFIG_TOPO_API}    ${config_store_elements}    pretty_print_json=True
     ${ovs_output} =    Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl show
     BuiltIn.Log    ${ovs_output}
     ${ovs_output} =    Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl del-manager
@@ -165,11 +166,11 @@ Bug 8280
     OVSDB.Verify Ovs-vsctl Output    show    Port "port2"    ${TOOLS_SYSTEM_IP}    False
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl set-manager tcp:${ODL_SYSTEM_IP}:${OVSDBPORT}
     BuiltIn.Wait Until Keyword Succeeds    5s    1s    OVSDB.Verify OVS Reports Connected    ${TOOLS_SYSTEM_IP}
-    Utils.Check For Elements At URI    ${CONFIG_TOPO_API}    ${config_store_elements}    pretty_print_json=True
+    Utils.Check For Elements At URI    ${RFC8040_CONFIG_TOPO_API}    ${config_store_elements}    pretty_print_json=True
     BuiltIn.Wait Until Keyword Succeeds    5s    1s    Verify Ovs-vsctl Output    show    Port "port2"
     [Teardown]    BuiltIn.Run Keywords    Test Teardown
-    ...    AND    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}uuid%2F${OVSDB_UUID2}%2Fbridge%2F${BRIDGE}
-    ...    AND    RequestsLibrary.Delete Request    session    ${SOUTHBOUND_CONFIG_API}uuid%2F${OVSDB_UUID2}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID2}%2Fbridge%2F${BRIDGE}
+    ...    AND    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID2}
 
 Bug 7160
     [Documentation]    If this bug is reproduced, it's possible that the operational store will be
@@ -188,17 +189,16 @@ Bug 7160
     OVSDB.Log Config And Operational Topology
     OVSDB.Create Qos Linked Queue
     OVSDB.Log Config And Operational Topology
-    ${resp}    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:qos-entries/${qos}/queue-list/0/
+    ${resp}    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:qos-entries=${qos}/queue-list=0
     OVSDB.Log Config And Operational Topology
-    ${resp}    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:qos-entries/${qos}/
+    ${resp}    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:qos-entries=${qos}
     OVSDB.Log Config And Operational Topology
-    ${resp}    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1/ovsdb:queues/${queue}/
+    ${resp}    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}/ovsdb:queues=${queue}
     OVSDB.Log Config And Operational Topology
-    ${resp}    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/ovsdb:HOST1
+    ${resp}    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_HOST1_API}
     OVSDB.Log Config And Operational Topology
     Utils.Run Command On Mininet    ${TOOLS_SYSTEM_IP}    sudo ovs-vsctl del-manager
-    ${node}    BuiltIn.Set Variable    ovsdb:%2F%2F${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
     OVSDB.Log Config And Operational Topology
     BuiltIn.Wait Until Keyword Succeeds    5s    1s    OVSDB.Config and Operational Topology Should Be Empty
 
@@ -217,15 +217,12 @@ Suite Teardown
     [Documentation]    Cleans up test environment, close existing sessions.
     Clean All Ovs Nodes
     # Best effort to clean config store, by deleting all the types of nodes that are used in this suite
-    ${node} =    BuiltIn.Set Variable    ovsdb:%2F%2Fuuid%2F${OVSDB_UUID}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}%2Fbridge%2F${BRIDGE}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}
-    ${node} =    BuiltIn.Set Variable    ovsdb:%2F%2Fuuid%2F${OVSDB_UUID2}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}%2Fbridge%2F${BRIDGE}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}
-    ${node} =    BuiltIn.Set Variable    ovsdb:%2F%2F${TOOLS_SYSTEM_IP}:${OVSDB_NODE_PORT}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}%2Fbridge%2F${BRIDGE}
-    RequestsLibrary.Delete Request    session    ${CONFIG_TOPO_API}/topology/ovsdb:1/node/${node}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID}%2Fbridge%2F${BRIDGE}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID2}%2Fbridge%2F${BRIDGE}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_API}uuid%2F${OVSDB_UUID2}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}%2Fbridge%2F${BRIDGE}
+    RequestsLibrary.Delete Request    session    ${RFC8040_SOUTHBOUND_NODE_TOOLS_API}
     OVSDB.Log Config And Operational Topology
     Delete All Sessions
 
diff --git a/csit/variables/ovsdb/Variables.robot b/csit/variables/ovsdb/Variables.robot
new file mode 100644 (file)
index 0000000..c196740
--- /dev/null
@@ -0,0 +1,18 @@
+*** Settings ***
+Documentation     Resource file containing OVSDB variables.
+
+*** Variables ***
+${OVSDB_NODE_PORT}    6634
+${RFC8040_RESTCONF_ROOT}    /rests
+${RFC8040_DATA_RESOURCE}    ${RFC8040_RESTCONF_ROOT}/data
+${RFC8040_CONFIG_CONTENT}    content=config
+${RFC8040_OPERATIONAL_CONTENT}    content=nonconfig
+${RFC8040_TOPO_API}    ${RFC8040_DATA_RESOURCE}/network-topology:network-topology
+${RFC8040_CONFIG_TOPO_API}    ${RFC8040_TOPO_API}?${RFC8040_CONFIG_CONTENT}
+${RFC8040_OPERATIONAL_TOPO_API}    ${RFC8040_TOPO_API}?${RFC8040_OPERATIONAL_CONTENT}
+${RFC8040_TOPO_OVSDB1_API}    ${RFC8040_TOPO_API}/topology=ovsdb%3A1
+${RFC8040_CONFIG_TOPO_OVSDB1_API}    ${RFC8040_TOPO_OVSDB1_API}?${RFC8040_CONFIG_CONTENT}
+${RFC8040_OPERATIONAL_TOPO_OVSDB1_API}    ${RFC8040_TOPO_OVSDB1_API}?${RFC8040_OPERATIONAL_CONTENT}
+${RFC8040_SOUTHBOUND_NODE_API}    ${RFC8040_TOPO_OVSDB1_API}/node=ovsdb%3A%2F%2F
+${RFC8040_SOUTHBOUND_NODE_TOOLS_API}    ${RFC8040_SOUTHBOUND_NODE_API}${TOOLS_SYSTEM_IP}%3A${OVSDB_NODE_PORT}
+${RFC8040_SOUTHBOUND_NODE_HOST1_API}    ${RFC8040_TOPO_OVSDB1_API}/node=ovsdb%3AHOST1
index b0e382c9c2690d4e4ea2229196c9bd56ddd5b5e5..981c3512132582091215217d645405f7520a477c 100644 (file)
@@ -1,5 +1,5 @@
 {
-  "network-topology:node": [
+    "network-topology:node": [
         {
             "node-id": "ovsdb://127.0.0.1:61644/bridge/br01",
             "ovsdb:bridge-name": "br01",
@@ -19,7 +19,7 @@
                     "bridge-other-config-value": "0000000000000001"
                 }
             ],
-            "ovsdb:managed-by": "/network-topology:network-topology/network-topology:topology[network-topology:topology-id='ovsdb:1']/network-topology:node[network-topology:node-id='ovsdb://127.0.0.1:61644']"
+            "ovsdb:managed-by": "/network-topology:network-topology/topology[topology-id='ovsdb:1']/node[node-id='ovsdb://127.0.0.1:61644']"
         }
     ]
 }
index 3e86f6d2bcbe14b0a927a816922c91a9ab2c0236..2b7b57f5973ddf0d94b4309706b6f9cde44b2dd0 100644 (file)
@@ -1,5 +1,5 @@
 {
-  "node": [
+    "network-topology:node": [
         {
             "node-id": "ovsdb://127.0.0.1:61644/bridge/br01",
             "ovsdb:bridge-name": "br01",
@@ -25,7 +25,7 @@
                     "bridge-other-config-value": "0000000000000001"
                 }
             ],
-            "ovsdb:managed-by": "/network-topology:network-topology/network-topology:topology[network-topology:topology-id='ovsdb:1']/network-topology:node[network-topology:node-id='ovsdb://127.0.0.1:61644']"
+            "ovsdb:managed-by": "/network-topology:network-topology/topology[topology-id='ovsdb:1']/node[node-id='ovsdb://127.0.0.1:61644']"
         }
     ]
 }
index 2ec84beca19e6fe62e34051fc350fc202643be90..594927f545ff70eba1553352f5b4b3bd3f0e4179 100644 (file)
@@ -1,15 +1,15 @@
 {
-   "network-topology:termination-point": [
-      {
-             "ovsdb:options": [
-                    {
-                  "ovsdb:option": "remote_ip",
-                  "ovsdb:value" : "192.168.0.21"
-                        }
-                        ],
-                   "ovsdb:interface-type": "ovsdb:interface-type-vxlan",
-                        "ovsdb:name": "vxlanport",
-                        "tp-id": "vxlanport"
-             }
-     ]
+    "network-topology:termination-point": [
+        {
+            "ovsdb:options": [
+                {
+                    "ovsdb:option": "remote_ip",
+                    "ovsdb:value": "192.168.0.21"
+                }
+            ],
+            "ovsdb:interface-type": "ovsdb:interface-type-vxlan",
+            "ovsdb:name": "vxlanport",
+            "tp-id": "vxlanport"
+        }
+    ]
 }
index 98be2021633c8ee4d672b8078f2fa9b76438e78d..dec38aa4d2c917f7611f16c35aee165d5dc895c3 100644 (file)
@@ -1,15 +1,15 @@
 {
-   "termination-point": [
-      {
-         "ovsdb:options": [
-                  {
-                "option": "remote_ip",
-                "value" : "192.168.1.10"
-                      }
-                      ],
-                "ovsdb:interface-type": "ovsdb:interface-type-vxlan",
-                     "ovsdb:name": "vx2",
-                     "tp-id": "vx2"
-           }
-      ]
+    "network-topology:termination-point": [
+        {
+            "ovsdb:options": [
+                {
+                    "option": "remote_ip",
+                    "value": "192.168.1.10"
+                }
+            ],
+            "ovsdb:interface-type": "ovsdb:interface-type-vxlan",
+            "ovsdb:name": "vx2",
+            "tp-id": "vx2"
+        }
+    ]
 }