The column was added to expose DGP information to the CMS but ovn-northd
never reads it and shouldn't be notified about its changes.  The CMS
should also never write to it.

Omit updates to it, otherwise ovn-northd unnecessarily wakes up after
its own transaction that set it was committed in the NB.

Even worse, these updates break incremental processing of router
datapaths (if they're the only changes that happened in the NB) because
lr_changes_can_be_handled() assumes it's a relevant LRP change.

Update the existing tests accordingly.

Fixes: 19164b030404 ("Expose distributed gateway port information in NB DB")
Signed-off-by: Dumitru Ceara <[email protected]>
---
 northd/ovn-northd.c |  2 ++
 tests/ovn-northd.at | 11 ++---------
 2 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/northd/ovn-northd.c b/northd/ovn-northd.c
index e2d1066ada..c3c198f2f3 100644
--- a/northd/ovn-northd.c
+++ b/northd/ovn-northd.c
@@ -886,6 +886,8 @@ main(int argc, char *argv[])
     ovsdb_idl_omit_alert(ovnnb_idl_loop.idl, &nbrec_nb_global_col_hv_cfg);
     ovsdb_idl_omit_alert(ovnnb_idl_loop.idl,
                          &nbrec_nb_global_col_hv_cfg_timestamp);
+    ovsdb_idl_omit_alert(ovnnb_idl_loop.idl,
+                         &nbrec_logical_router_port_col_status);
 
     /* Ignore northbound external IDs, except for logical switch, router and
      * their ports, for which the external IDs are propagated to corresponding
diff --git a/tests/ovn-northd.at b/tests/ovn-northd.at
index 2e92a18f4c..1ae6e04800 100644
--- a/tests/ovn-northd.at
+++ b/tests/ovn-northd.at
@@ -303,11 +303,6 @@ check ovn-nbctl --wait=sb sync
 # Check for the hosting-chassis status being set by northd
 wait_row_count nb:Logical_Router_Port 1 name=lrp1 status:hosting-chassis=ch1
 
-# Clear the hosting-chassis status from LRP and assert northd repopulates it
-check ovn-nbctl remove logical_router_port lrp1 status hosting-chassis
-check ovn-nbctl --wait=sb sync
-wait_row_count nb:Logical_Router_Port 1 name=lrp1 status:hosting-chassis=ch1
-
 # Now remove the chassis from the port binding record and assert that the
 # hosting-chassis status was removed by northd
 check ovn-sbctl clear Port_Binding cr-lrp1 chassis
@@ -11786,12 +11781,10 @@ check as northd ovn-appctl -t ovn-northd 
inc-engine/clear-stats
 check ovn-nbctl --wait=sb lrp-set-gateway-chassis lrp hv1
 wait_column "hosting-chassis=hv1" nb:Logical_Router_Port status name=lrp
 
-# There will be 3 recomputes of northd engine node
+# There will be 2 recomputes of northd engine node
 #   1. missing handler for input NB_logical_router
 #   2. missing handler for input SB_ha_chassis_group
-#   3. missing handler for input NB_logical_router when ovn-northd
-#      updates the hosting-chassis option in NB_logical_router_port.
-check_recompute_counter 3 3
+check_recompute_counter 2 2
 CHECK_NO_CHANGE_AFTER_RECOMPUTE
 
 check as northd ovn-appctl -t ovn-northd inc-engine/clear-stats
-- 
2.54.0

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to