[ovs-dev] [PATCH] tests: Add delay in NetFlow unit tests before killing processes.

Ben Pfaff blp at nicira.com
Mon Aug 13 23:02:54 UTC 2012


On Wed, Aug 08, 2012 at 07:21:23PM -0700, Jesse Gross wrote:
> At the end of the NetFlow unit tests we warp time to force any
> remaining flows to expire and then immediately kill OVS and the
> collector.  However, this creates a race where sometimes these
> processes are killed before the last records are sent or collected.
> It's possible to force OVS to go through the run loop one last time
> before exiting but it's harder to enforce that the collector receives
> the packet.  This simply avoids the problem by adding a 1 second delay
> before killing the processes, which should be more than enough time.
> 
> Signed-off-by: Jesse Gross <jesse at nicira.com>

Thanks, this looks good.  Sleeping in the unit tests isn't ideal but
it's better than failing.



More information about the dev mailing list