[ovs-git] [openvswitch/ovs] d18e52: ovsdb-idl: Tolerate missing tables and columns.

GitHub noreply at github.com
Wed Apr 1 00:14:05 UTC 2015


  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: d18e52e3d97ee160b19a55927876423add24a13a
      https://github.com/openvswitch/ovs/commit/d18e52e3d97ee160b19a55927876423add24a13a
  Author: Ben Pfaff <blp at nicira.com>
  Date:   2015-03-31 (Tue, 31 Mar 2015)

  Changed paths:
    M lib/ovsdb-idl.c
    M lib/ovsdb-parser.c
    M lib/ovsdb-parser.h
    M tests/automake.mk
    A tests/idltest2.ovsschema
    M tests/ovsdb-idl.at

  Log Message:
  -----------
  ovsdb-idl: Tolerate missing tables and columns.

Until now, if ovs-vsctl (or another client of the C ovsdb-idl library) was
compiled against a schema that had a column or table that was not in the
database actually being used (e.g. during an upgrade), and the column or
table was selected for monitoring, then ovsdb-idl would fail to get any
data at all because ovsdb-server would report an error due to a request
about a column or a table it didn't know about.

This commit fixes the problem by making ovsdb-idl retrieve the database
schema from the database server and omit any tables or columns that don't
exist from its monitoring request.  This works OK for the kinds of upgrades
that OVSDB otherwise supports gracefully because it will simply make the
missing columns or tables appear empty, which clients of the ovsdb-idl
library already have to tolerate.

VMware-BZ: #1413562
Reported-by: Alex Wang <alexw at nicira.com>
Signed-off-by: Ben Pfaff <blp at nicira.com>
Acked-by: Alex Wang <alexw at nicira.com>


  Commit: 508624b691e1517e4d426aa69165ea1efba80d53
      https://github.com/openvswitch/ovs/commit/508624b691e1517e4d426aa69165ea1efba80d53
  Author: Ben Pfaff <blp at nicira.com>
  Date:   2015-03-31 (Tue, 31 Mar 2015)

  Changed paths:
    M ovsdb/jsonrpc-server.c
    M ovsdb/ovsdb-server.1.in
    M tests/ovsdb-server.at

  Log Message:
  -----------
  ovsdb-server: Correct malformed error replies to certain JSON-RPC requests.

I realized that this bug existed only a few weeks ago, but it has been
there since the earliest ovsdb-server code.

Signed-off-by: Ben Pfaff <blp at nicira.com>
Acked-by: Alex Wang <alexw at nicira.com>


Compare: https://github.com/openvswitch/ovs/compare/da1e25d5af82...508624b691e1


More information about the git mailing list