[ovs-dev] [PATCH 3/3] ovn-controller: Add test for setting up and tearing down patch ports.
Ben Pfaff
blp at nicira.com
Wed Oct 7 21:32:09 UTC 2015
On Wed, Oct 07, 2015 at 02:25:18PM -0700, Justin Pettit wrote:
>
> > On Oct 7, 2015, at 1:57 PM, Ben Pfaff <blp at nicira.com> wrote:
> >
> > +# Waits until the OVS database contains exactly the specified patch ports.
> > +# Each argument should be of the form BRIDGE PORT PEER.
> > +check_patches () {
> > + # Generate code to check that the set of patch ports is exactly as
> > + # specified.
> > + printf > query 'ovs-vsctl -f csv -d bare --no-headings --columns=name find interface type=patch | sort
> > +ovs-vsctl init'
>
> I think it would be helpful to explain why "ovs-vsctl init" is being
> used. I got hung up on "ovs-vsctl init" and not the fact that it was
> building an ovs-vsctl command with a variable number of arguments,
> which could be zero, in which case the "init" is a no-op that allows
> the command to run without generating an error.
Thanks for pointing that out.
On reflection, this is only there to allow for a single call to
ovs-vsctl instead of one per port. It's easier to understand if the
code just dumps out a separate ovs-vsctl command per port, so I just
made that change instead.
> Acked-by: Justin Pettit <jpettit at nicira.com>
Thanks, I've applied these patches now.
More information about the dev
mailing list