Re: Standby catch up state change - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Standby catch up state change
Date
Msg-id 20131015102913.GD5300@awork2.anarazel.de
Whole thread Raw
In response to Standby catch up state change  (Pavan Deolasee <pavan.deolasee@gmail.com>)
Responses Re: Standby catch up state change  (Pavan Deolasee <pavan.deolasee@gmail.com>)
List pgsql-hackers
On 2013-10-15 15:51:46 +0530, Pavan Deolasee wrote:
> Should we not instead wait for the standby to have received all the WAL
> before declaring that it has caught up ? If a failure happens while the
> data is still in the sender's buffer, the standby may not actually catch up
> to the desired point contrary to the LOG message displayed on the master.

I don't think that'd be a good idea - the "caughtup" logic is used to
determine whether we need to wait for further wal to be generated
locally if we haven't got anything else to do. And we only need to do so
when we reached the end of the WAL.

Also, we'd have to reset caughtup everytime we send data (in
XLogSend()), that'd be horrible.

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Pavan Deolasee
Date:
Subject: Standby catch up state change
Next
From: Pavan Deolasee
Date:
Subject: Re: Standby catch up state change