On Tue, May 12, 2020 at 1:08 AM Mark Michelson <[email protected]> wrote:
> A recent build failed because the pause and resume test failed. After > resuming northd and northd-backup, the status of northd was "standby" > instead of the expected "active". This happened for one of two reasons: > > 1) For some reason, northd failed to retrieve the lock between resuming > and checking its status, so it reported as being "standby". > 2) northd-backup won the race to get the lock, so it became the active > instance instead of northd. > > This change alters the test to fix both of these issues. Instead of > resuming both northd and northd-backup, we start by only resuming > northd. We then wait until it reports that it is active before we resume > northd-backup. This way, they are guaranteed to be in the states we > expect. > > Signed-off-by: Mark Michelson <[email protected]> > Acked-by: Numan Siddique <[email protected]> Thanks > --- > tests/ovn-northd.at | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/tests/ovn-northd.at b/tests/ovn-northd.at > index 57c9eedd5..80bda0a15 100644 > --- a/tests/ovn-northd.at > +++ b/tests/ovn-northd.at > @@ -935,10 +935,12 @@ OVS_WAIT_UNTIL([ > > # Now resume ovn-northd > as northd ovs-appctl -t ovn-northd resume > -as northd-backup ovs-appctl -t ovn-northd resume > AT_CHECK([test xfalse = x`as northd ovn-appctl -t ovn-northd is-paused`]) > -AT_CHECK([as northd ovn-appctl -t ovn-northd status], [0], [Status: active > +OVS_WAIT_UNTIL([as northd ovn-appctl -t ovn-northd status], [0], > +[Status: active > ]) > + > +as northd-backup ovs-appctl -t ovn-northd resume > AT_CHECK([test xfalse = x`as northd-backup ovn-appctl -t ovn-northd \ > is-paused`]) > AT_CHECK([as northd-backup ovn-appctl -t ovn-northd status], [0], > -- > 2.25.4 > > _______________________________________________ > dev mailing list > [email protected] > https://mail.openvswitch.org/mailman/listinfo/ovs-dev > > _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
