Message ID | 1482227237-61638-1-git-send-email-azhou@ovn.org |
---|---|
State | Accepted |
Headers | show |
On Tue, Dec 20, 2016 at 01:47:15AM -0800, Andy Zhou wrote: > In case connection is reset when there are buffered but unsent > conditions, these conditions will be sent as the new "monitor_cond" > message that will be sent after the idl reconnects. > > Without this patch, those conditions will be unnecessarily sent again > with following monitoring condition update message. > > Signed-off-by: Andy Zhou <azhou@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
On Thu, Dec 22, 2016 at 8:56 AM, Ben Pfaff <blp@ovn.org> wrote: > On Tue, Dec 20, 2016 at 01:47:15AM -0800, Andy Zhou wrote: > > In case connection is reset when there are buffered but unsent > > conditions, these conditions will be sent as the new "monitor_cond" > > message that will be sent after the idl reconnects. > > > > Without this patch, those conditions will be unnecessarily sent again > > with following monitoring condition update message. > > > > Signed-off-by: Andy Zhou <azhou@ovn.org> > > Acked-by: Ben Pfaff <blp@ovn.org> > Thanks. Pushed to master.
diff --git a/lib/ovsdb-idl.c b/lib/ovsdb-idl.c index 1be1c68..218b6b3 100644 --- a/lib/ovsdb-idl.c +++ b/lib/ovsdb-idl.c @@ -345,6 +345,7 @@ ovsdb_idl_clear(struct ovsdb_idl *idl) struct ovsdb_idl_table *table = &idl->tables[i]; struct ovsdb_idl_row *row, *next_row; + table->cond_changed = false; if (hmap_is_empty(&table->rows)) { continue; } @@ -370,6 +371,7 @@ ovsdb_idl_clear(struct ovsdb_idl *idl) } } + idl->cond_changed = false; ovsdb_idl_track_clear(idl); if (changed) {
In case connection is reset when there are buffered but unsent conditions, these conditions will be sent as the new "monitor_cond" message that will be sent after the idl reconnects. Without this patch, those conditions will be unnecessarily sent again with following monitoring condition update message. Signed-off-by: Andy Zhou <azhou@ovn.org> --- lib/ovsdb-idl.c | 2 ++ 1 file changed, 2 insertions(+)