Make walsender more responsive.

Robert Haas <rhaas@postgresql.org>

Commit: f83b59997d29f06c3d67e7eb9a1f2c9cd017d665
Author: Robert Haas <rhaas@postgresql.org>
Date: 2012-07-02T13:41:01Z
Releases: 9.3.0
Make walsender more responsive.

Per testing by Andres Freund, this improves replication performance
and reduces replication latency and latency jitter.  I was a bit
concerned about moving more work into XLogInsert, but testing seems
to show that it's not a problem in practice.

Along the way, improve comments for WaitLatchOrSocket.

Andres Freund.  Review and stylistic cleanup by me.

Files