pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andreas Pflug <pgadmin@pse-consulting.de>
To: Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Warm Standby restore_command documentation
Date: Mon, 20 Apr 2009 13:10:55 +0200
Message-ID: <49EC583F.1020106@pse-consulting.de> (raw)
In-Reply-To: <49EC3317.7090209@enterprisedb.com>
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>
	<49EC3317.7090209@enterprisedb.com>

Heikki Linnakangas wrote:
> 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. 
After reading that chapter, I assumed that pg_standby actually does work
like this, and skipped reading the pg_standby specific doc....
The pgsql doc tries hard to give best advice for common situations,
especially for integrity and safety issues. IMHO it's best to have the
warm-standby chapter as reference how things should work for typical
use-cases.

Regards,
Andreas






view thread (4+ messages)

Message-ID: <49EC583F.1020106@pse-consulting.de>
Permalink:  ../49EC583F.1020106@pse-consulting.de/
Also on:    postgresql.org/message-id/49EC583F.1020106@pse-consulting.de

 · 

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: pgadmin@pse-consulting.de, heikki.linnakangas@enterprisedb.com
  Subject: Re: Warm Standby restore_command documentation
  In-Reply-To: <49EC583F.1020106@pse-consulting.de>

* 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