pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
To: Andreas Pflug <pgadmin@pse-consulting.de>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Warm Standby restore_command documentation
Date: Mon, 20 Apr 2009 11:32:23 +0300
Message-ID: <49EC3317.7090209@enterprisedb.com> (raw)
In-Reply-To: <49E4D643.3050707@pse-consulting.de>
References: <3f0b79eb0903242329j12865d55s348f5c873a956e71@mail.gmail.com>
	<3f0b79eb0903311901h70520cc8u9c0f1d8f4193923b@mail.gmail.com>
	<3f0b79eb0904022042g35b8e3cah9432ff764e721a3@mail.gmail.com>
	<1d4e0c10904071456m735e3f67q123b87243d2f6f2a@mail.gmail.com>
	<3f0b79eb0904071817u5c32254ei61f7e68e54669d9e@mail.gmail.com>
	<49DDEE72.6030803@enterprisedb.com>
	<3f0b79eb0904092047w355e0b3ar527a9285b161ef91@mail.gmail.com>
	<1239381103.16396.30.camel@ebony.2ndQuadrant>
	<3f0b79eb0904122252t1f4c5860v919d199f399ccf72@mail.gmail.com>
	<1239701740.16396.86.camel@ebony.2ndQuadrant>
	<3f0b79eb0904140320m29b82150k38dd46e30e78ced9@mail.gmail.com>
	<49E4D643.3050707@pse-consulting.de>

Andreas Pflug wrote:
> I've been following the thread with growing lack of understanding why
> this is so hardly discussed, and I went back to the documentation of
> what the restore_command should do (
> http://www.postgresql.org/docs/8.3/static/warm-standby.html )
> 
> While the algorithm presented in the pseudocode isn't dealing too good
> with a situation where the trigger is set while the restore_command is
> sleeping (this should be handled better in a real implementation), the
> code says
> 
> "Restore all wal files. If no more wal files are present, stop restoring
> if the trigger is set; otherwise wait for a new wal file".
> 
> Since pg_standby is meant as implementation of restore_command, it has
> to follow the directive stated above; *anything else is a bug*.
> pg_standby currently does *not* obey this directive, and has that
> documented, but a documented bug still is a bug.

I think you're interpreting the chapter too strongly. The provided 
pseudo-code is just an example of a suitable restore_command, it doesn't 
say that pg_standby behaves exactly like that.

I agree we should change the default behavior, though.

-- 
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com



view thread (4+ messages)  latest in thread

Message-ID: <49EC3317.7090209@enterprisedb.com>
Permalink:  ../49EC3317.7090209@enterprisedb.com/
Also on:    postgresql.org/message-id/49EC3317.7090209@enterprisedb.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: heikki.linnakangas@enterprisedb.com, pgadmin@pse-consulting.de
  Subject: Re: Warm Standby restore_command documentation
  In-Reply-To: <49EC3317.7090209@enterprisedb.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox