Re: Keepalive for max_standby_delay - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Keepalive for max_standby_delay
Date
Msg-id 25768.1273938352@sss.pgh.pa.us
Whole thread Raw
In response to Keepalive for max_standby_delay  (Simon Riggs <simon@2ndQuadrant.com>)
Responses Re: Keepalive for max_standby_delay
List pgsql-hackers
Simon Riggs <simon@2ndQuadrant.com> writes:
> Patch adds a keepalive message to ensure max_standby_delay is useful.

The proposed placement of the keepalive-send is about the worst it could
possibly be.  It needs to be done right before pq_flush to ensure
minimum transfer delay.  Otherwise any attempt to measure clock skew
using the timestamp will be seriously off.  Where you've placed it
guarantees maximum delay not minimum.

I'm also extremely dubious that it's a good idea to set
recoveryLastXTime from this.  Using both that and the timestamps from
the wal log flies in the face of everything I remember about control
theory.  We should be doing only one or only the other, I think.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Rob Wultsch
Date:
Subject: Re: List traffic
Next
From: Simon Riggs
Date:
Subject: Re: Keepalive for max_standby_delay