summaryrefslogtreecommitdiff
path: root/ovsdb/automake.mk
diff options
context:
space:
mode:
authorBen Pfaff <blp@ovn.org>2017-12-15 11:14:55 -0800
committerBen Pfaff <blp@ovn.org>2018-03-24 12:04:52 -0700
commit6bb9b060d5b0f972461f0c061a865393611fd86a (patch)
tree9acfdc5a3374821cd97c0da88b9593f4ffb3e0a4 /ovsdb/automake.mk
parent00d5d6310da15bf0530cb9a7a73acce325636b44 (diff)
downloadopenvswitch-6bb9b060d5b0f972461f0c061a865393611fd86a.tar.gz
ovsdb-server: Add support for a built-in _Server database.
The _Server database is valuable primarily because it provides database clients a way to find out the details of changes to databases, schemas, etc. in a granular, natural way. Until now, the only way that the server could notify clients about these kinds of changes was to close the session; when the client reconnects, it is expected to reassess the server's state. One way to provide this kind of granular information would be to add specific JSON-RPC requests to obtain notifications for different kinds of changes, but since ovsdb-server already provides granular and flexible notification support for databases, using a database for the purpose is convenient and avoids duplicating functionality. Initially this database only reports databases' names and schemas, but when clustering support is added in a later commit it will also report important aspects of clustering and cluster status. Thus, this database also reduces the need to add JSON-RPC calls to retrieve information about new features. Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'ovsdb/automake.mk')
-rw-r--r--ovsdb/automake.mk25
1 files changed, 25 insertions, 0 deletions
diff --git a/ovsdb/automake.mk b/ovsdb/automake.mk
index d040fc6de..5760cba44 100644
--- a/ovsdb/automake.mk
+++ b/ovsdb/automake.mk
@@ -109,3 +109,28 @@ EXTRA_DIST += ovsdb/ovsdb-dot.in ovsdb/dot2pic
noinst_SCRIPTS += ovsdb/ovsdb-dot
CLEANFILES += ovsdb/ovsdb-dot
OVSDB_DOT = $(run_python) $(srcdir)/ovsdb/ovsdb-dot.in
+
+EXTRA_DIST += ovsdb/_server.ovsschema
+CLEANFILES += ovsdb/_server.ovsschema.inc
+ovsdb/ovsdb-server.o: ovsdb/_server.ovsschema.inc
+ovsdb/_server.ovsschema.inc: ovsdb/_server.ovsschema $(srcdir)/build-aux/text2c
+ $(AM_V_GEN)$(run_python) $(srcdir)/build-aux/text2c < $< > $@.tmp
+ $(AM_V_at)mv $@.tmp $@
+
+# Version checking for _server.ovsschema.
+ALL_LOCAL += ovsdb/_server.ovsschema.stamp
+ovsdb/_server.ovsschema.stamp: ovsdb/_server.ovsschema
+ $(srcdir)/build-aux/cksum-schema-check $? $@
+CLEANFILES += ovsdb/_server.ovsschema.stamp
+
+# _Server schema documentation
+EXTRA_DIST += ovsdb/_server.xml
+CLEANFILES += ovsdb/ovsdb-server.5
+man_MANS += ovsdb/ovsdb-server.5
+ovsdb/ovsdb-server.5: \
+ ovsdb/ovsdb-doc ovsdb/_server.xml ovsdb/_server.ovsschema
+ $(AM_V_GEN)$(OVSDB_DOC) \
+ --version=$(VERSION) \
+ $(srcdir)/ovsdb/_server.ovsschema \
+ $(srcdir)/ovsdb/_server.xml > $@.tmp && \
+ mv $@.tmp $@