[ovs-git] [openvswitch/ovs] d5b332: expr: New function expr_parse_microflow().

GitHub noreply at github.com
Tue Aug 16 02:47:47 UTC 2016

  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: d5b332799f90d5bab8c4d80c044e95008d7403fb
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-08-15 (Mon, 15 Aug 2016)

  Changed paths:
    M include/ovn/expr.h
    M ovn/lib/expr.c
    M tests/test-ovn.c

  Log Message:
  expr: New function expr_parse_microflow().

This allows "ovstest test-ovn evaluate-expr" to work with arbitrary
microflows rather than just a few restricted variables, but the main point
is to enable the upcoming "ovn-trace" utility to accept arbitrary
microflows in a format that seems reasonable for OVN.

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Ryan Moats <rmoats at us.ibm.com>
Acked-by: Justin Pettit <jpettit at ovn.org>

  Commit: 4acd1e87a8bf931a30bb0df9411be039ae1ecad8
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-08-15 (Mon, 15 Aug 2016)

  Changed paths:
    M include/openvswitch/meta-flow.h
    M include/ovn/actions.h
    M lib/automake.mk
    A lib/daemon.xml
    M ovn/lib/actions.c
    M ovn/utilities/automake.mk
    A ovn/utilities/ovn-trace.8.xml
    A ovn/utilities/ovn-trace.c
    M tests/ovn.at

  Log Message:
  ovn-trace: New utility.

This new utility is intended to fulfill for OVN the purpose that
"ofproto/trace" has for Open vSwitch.  First, it's meant to be a useful
tool for troubleshooting and diagnosis and in general for improving one's
understanding of the emergent properties of a flow table.  Second, it
simplifies and increases the practical scope of testing, as well as making
testing more reliable and repeatable and failures easier to interpret.

This commit adds only a single test that uses the new utility, based on the
oldest OVN end-to-end test "ovn -- 3 HVs, 1 LS, 3 lports/HV".  The
differences between the old and the new test illustrate properties of
tracing.  First, the new test does not start any ovn-controller processes
or simulate any hypervisors in a nontrivial way.  This is because ovn-trace
does not actually forward packets or rely on the physical structure of the
system.  Second, whereas the old test tested not just the logical but also
the physical structure of the system, it needed to have several logical
ports, a total of 9 (3 on each of 3 HVs), whereas since this test only
tests the logical network implementation it can use a smaller number.  This
property also means that the new test runs signicantly faster than the old
one (less than a second on my laptop).

In my opinion this approach points the way toward the future of OVN
testing.  Certainly, we need end-to-end tests.  However, I believe that the
bulk of our tests can be broken into ones that test the logical network
implementation (using tracing) and ones that test physical/logical

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Ryan Moats <rmoats at us.ibm.com>

Compare: https://github.com/openvswitch/ovs/compare/803a6f3d3254...4acd1e87a8bf

More information about the git mailing list