vlog: Use worker process to write to log file.
authorBen Pfaff <blp@nicira.com>
Wed, 27 Jun 2012 17:42:34 +0000 (10:42 -0700)
committerBen Pfaff <blp@nicira.com>
Wed, 18 Jul 2012 17:30:50 +0000 (10:30 -0700)
commitcbb13e8e4c3e5766202ebe68bed9e414f62fa1c7
treed3adc002b81378f2dc05dfd203f6034e1bcdcaf4
parent9eb945635e1e780042b86e5a1ec47319e74aac4c
vlog: Use worker process to write to log file.

Writes to regular files under Unix-like kernels, including Linux, typically
block until the write is complete, regardless of O_NONBLOCK.  When the I/O
subsystem is busy, this can cause indefinite delays.  We have actually
observed "write" calls sleep for 5 seconds or more for this reason.

Delegating to a subprocess through the worker mechanism should solve the
problem.

Signed-off-by: Ben Pfaff <blp@nicira.com>
lib/vlog.c