Re: time-delayed standbys - Mailing list pgsql-hackers

From Greg Stark
Subject Re: time-delayed standbys
Date
Msg-id BANLkTimTm48ZKYrj4jGDCYuqWBUqZb+q2Q@mail.gmail.com
Whole thread Raw
In response to Re: time-delayed standbys  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: time-delayed standbys
List pgsql-hackers
On Wed, Apr 20, 2011 at 3:19 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> My idea of how to manage it would be to have walreceiver explicitly
> track the clock difference from the master, which it can do since
> walsender puts its current time into every message header.  You can use
> the slave's clock for comparisons so long as you add the appropriate
> offset.  (The theory here is that the skew won't change very fast ...)
>

Ah, so we did put the master's clock in every message? Then this
should be simple, no? Just compare the master's timestamp from the
record to the last master's clock seen in the messages. That sounds
equivalent but a lot safer than trying to keep a conversion between
them.


--
greg


pgsql-hackers by date:

Previous
From: Greg Stark
Date:
Subject: Re: REINDEX vs broken HOT chains, redux
Next
From: Tom Lane
Date:
Subject: Re: REINDEX vs broken HOT chains, redux