Age | Commit message (Collapse) | Author |
|
ovs-vswitchd.conf.db.5 has autogenerated text "at least -1" in one place.
This '-' should be a minus sign, but ovsdb-doc was generating it as a
hyphen.
Found by lintian.
Reported-by: Thomas Goirand <zigo@debian.org>
Reviewed-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
|
|
ovs-vswitchd.conf.db.5 contains the following sentence:
If the interface cannot be added then Open vSwitch sets this column
to -1.
The '-' in "-1" should be a minus sign, not a hyphen, but the heuristic
in ovsdb-doc wasn't smart enough. This commit improves the heuristic and
fixes the problem.
Found by lintian.
Reported-by: Thomas Goirand <zigo@debian.org>
Reviewed-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
|
|
This makes the manpage indexable by standard system tools.
Found by lintian.
Reported-by: Thomas Goirand <zigo@debian.org>
Reviewed-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
|
|
The commit 0993b66 (man: pic failed to run during manpage-check) worked
around the manpage-check warning generated by groff. Using "-T ascii"
rather "-T utf8" was enough to silence the warning because the man page
has this condition in it:
.if !'\*[.T]'ascii'
However, rpmlint generates the same warning as manpage-check was (it
uses -Tutf8), and manpages are generated using -Tutf8 (leading to an
fairly unreadable drawing). So let's change the logic a bit and allow
pdf generation w/ nice drawing and kill it for tty's.
Cc: Ethan Jackson <ethan@nicira.com>
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Ben Pfaff <blp@nicira.com>
|
|
Multiple-clause conditions in OVSDB operations with "where" clauses are
supposed to be conjunctions, that is, the condition is true only if every
clause is true. In fact, the implementation only checked a single clause
(not necessarily the first one) and ignored the rest. This fixes the
problem and adds test coverage for multiple-clause conditions.
Reported-by: Shih-Hao Li <shli@nicira.com>
|
|
This ensures that manpages actually get rebuilt if any of the lib/*.man
fragments that they depend upon are modified.
|
|
Now output that formerly looked like ["map", [["key1", "value1"], ["key2",
"value2"]]] is printed like {key1=value1, key2=value2}, which I find easier
to read.
|
|
The "show-log" command tries to give names to the rows to make it easier to
understand what's going on, but it's still important to see at least
partial UUIDs so that one can search the output for references to the rows
by UUID.
|
|
Initial versions of commit 8cdf034974 "python: Implement write support in
Python IDL for OVSDB" converted the OVSDB schemas to Python code so that
their Python clients could just import them. The final version instead
read the schemas from a file, but I forgot to remove some code that
generated the Python schema modules. This commit removes that code.
Reported-by: Ethan Jackson <ethan@nicira.com>
|
|
Suggested-by: Justin Pettit <jpettit@nicira.com>
|
|
The OVS configuration database now has numerous columns that contain fixed
key-value pairs. Currently there's no way to see these at a glance,
because they are not presented in the summary tables just before the
detailed descriptions.
This commit extends the XML format so that keys within a column can be
described individually, and rearranges and rewrites vswitch.xml to take
advantage of this feature.
|
|
|
|
Until now, the Python bindings for OVSDB have not supported writing to the
database. Instead, writes had to be done with "ovs-vsctl" subprocesses.
This commit adds write support and brings the Python bindings in line with
the C bindings.
This commit deletes the Python-specific IDL tests in favor of using the
same tests as the C version of the IDL, which now pass with both
implementations.
This commit updates the two users of the Python IDL to use the new write
support. I tested this updates only by writing unit tests for them,
which appear in upcoming commits.
|
|
Until now ovs.db.types.BaseType has kept track of the name of the
referenced table but not a reference to it. This commit renames the
ref_table attribute to ref_table_name and adds a new ref_table attribute
whose value is a reference to the named table.
This will be useful in an upcoming commit where table references are
actually followed.
|
|
|
|
|
|
This should catch future nroff syntax errors immediately, instead of much
later.
|
|
|
|
The "lock" request requires the lock name to be an <id> but it is shown as
<string> in the "assert" operation. This corrects the "assert"
specification and fixes the suggested naming convention (since ":" is not
valid in an <id>).
This commit also updates the implementation to match the specification.
Reported-by: Jeremy Stribling <strib@nicira.com>
|
|
Reported-by: Jeremy Stribling <strib@nicira.com>
|
|
Useful in an upcoming commit.
|
|
This provides clients a way to coordinate their access to the database.
This is a voluntary, not mandatory, locking protocols, that is, clients
are not prevented from modifying the database unless they cooperate with
the locking protocol. It is also not related to any of the ACID properties
of database transactions. It is strictly a way for clients to coordinate
among themselves.
The following commit will introduce one user.
|
|
An upcoming commit will need to expose the concept of a database session
to the execution engine, to allow the execution engine to query the locks
held by the session. This commit prepares for that by making sessions a
publicly visible data structure.
|
|
Inbound managers (e.g. "ptcp:") can have multiple active connections, but
the database schema doesn't allow us to report the status of more than one
at a time. This commit adds a status key-value pair that, when there is
more than one active connection, reports the number that are active. This
at least helps to clarify the issue.
|
|
ovsdb_jsonrpc_server keeps track of its remotes in a shash indexed on the
remote name specified in the database Manager record, but
ovsdb_jsonrpc_server_get_remote_status() added the name returned by
jsonrpc_session_get_name() to the shash returned to the ovsdb-server code.
If that name happened to be different (which is entirely possible because
the latter returns a "canonicalized" name in some cases) then the
ovsdb-server code couldn't find it. Furthermore, if an inbound (e.g.
"ptcp:") Manager got a connection and then lost it, the status info in
that Manager never got updated to reflect that, because the code considered
that that "couldn't happen" and didn't bother to do any updates.
This commit simplifies the logic. Now ovsdb-server just asks for a single
status record at a time, using the name that is indexed in the
ovsdb_jsonrpc_server shash, avoiding that whole issue.
|
|
In practice these arguments are almost always the defaults, so this change
makes ovsdb-client much more usable interactively.
|
|
In practice the default location is the only one used, so we might as well
make it easier.
|
|
.TP's argument is an optional indentation width, not a string. The string
goes on the next line.
vswitch.xml didn't actually cause .TQ to be used before, so this wasn't a
problem, but an upcoming commit does add a use, so this commit fixes the
problem in advance.
|
|
Recently I helped debug a scenario where ovsdb-server connected to a remote
manager, then ovs-vsctl deleted the remote manager and soon after re-added
it. The log was difficult to interpret because it showed two successful
connection attempts to the same remote without showing a reason why the
connection was dropped in the first place. Adding this log message would
make it clear that the configuration changed to remove that remote
connection in the meantime.
|
|
|
|
Adding the version number can make it clear what version of OVS screwed
something up as part of an upgrade or downgrade.
|
|
If 'error' is nonnull then we destroy the row, so we must not try to reuse
the row immediately after that.
Support request #6155.
Repoted-by: Geoff White <gwhite@nicira.com>
|
|
The comments and the code didn't match, so make them agree.
|
|
|
|
Now a specific key can be referenced with syntax like
<ref table="Bridge" column="other-config" key="datapath-id"/>.
Also fixes up an existing place that needed this feature already (and had
a typo, too).
|
|
CC: Jeremy Stribling <strib@nicira.com>
|
|
|
|
These will be used for formatting error messages in an upcoming commit.
|
|
This function is not useful inside ovsdb itself but only in the
"test-ovsdb" test program. To avoid the temptation to use it incorrectly
inside ovsdb, this commit moves it into the test program.
|
|
This function took a struct ovsdb_table but only used the 'schema' member.
An upcoming patch needs to parse a column set when only the schema is
available, so to prepare for that this patch changes
ovsdb_column_set_from_json() to only take the schema that it really needs.
|
|
Errors from this function were being ignored, which meant that transactions
could use "mutate" to bypass number-of-elements constraints on sets and
maps. This fixes the problem and adds a test to prevent the problem from
recurring.
Bug #5781.
|
|
|
|
The E-R diagram is illegible when rendered in ASCII, so exclude it from
that version only. The E-R diagram is still included in other versions of
the manpage (e.g. for PostScript output).
|
|
This makes the diagram even more informative.
|
|
|
|
The format of "ovs-dpctl dump-flows" has completely changed since
ovsdbmonitor was written. It seems like no one has tried out ovsdbmonitor
since the rewrite, because it didn't work at all. This commit fixes the
parser.
|
|
I can't figure out where JsonReader and JsonWriter come from. I know that
they must exist, because I (and others) have used ovsdbmonitor before, but
I can't find them now.
Switch to using ovs.json, which is part of Open vSwitch so we know that
it exists. At the same time, we have to start translating the Unicode
strings that ovs.json outputs into standard Python strings; otherwise
the "twisted conch" ssh implementation craps out because it tries to
concatenate this Unicode string with a standard string that contains
non-ASCII characters.
|
|
deamon.man allows the file that is including it to include extra text in
the description of --detach by defining a macro named DD. Only some of the
manpages that included it did this (only those manpages that needed extra
text there). But it's better to be quiet in "man --warnings", so this
defines DD to an empty value in the other manpages that include daemon.man.
Reported by lintian.
|
|
The sparse checker does not like taking sizeof(_Bool). Older versions of
sparse output a hard error ("error: cannot size expression"). Newer
versions output a warning ("warning: expression using sizeof bool"). This
commit avoids the problem by not using sizeof(_Bool) anywhere.
The only place where OVS uses sizeof(_Bool) anyway is in code generated by
the OVSDB IDL. It generates it for populating "optional bool" columns in
the database, that is, columns that are allowed to contain 0 or 1 instances
of a bool. For these columns, it generates code that looks roughly like
this:
row->column = xmalloc(sizeof *row->column);
*row->column = value;
This commit changes these columns from type "bool *" to type "const bool *"
and changes the generated code to:
static const bool true_value = true;
static const bool false_value = false;
row->column = value ? &true_value : &false_value;
which avoids the problem and saves a malloc() call at the same time.
The idltest code had a column with a slightly different type ("0, 1, or
2 bools") that didn't fit the revised pattern and is a fairly stupid type
anyhow, so I just changed it to "0 or 1 bools".
|
|
Found with sparse.
|