Go to file
Heikki Linnakangas 1bb2558046 Make standby server continuously retry restoring the next WAL segment with
restore_command, if the connection to the primary server is lost. This
ensures that the standby can recover automatically, if the connection is
lost for a long time and standby falls behind so much that the required
WAL segments have been archived and deleted in the master.

This also makes standby_mode useful without streaming replication; the
server will keep retrying restore_command every few seconds until the
trigger file is found. That's the same basic functionality pg_standby
offers, but without the bells and whistles.

To implement that, refactor the ReadRecord/FetchRecord functions. The
FetchRecord() function introduced in the original streaming replication
patch is removed, and all the retry logic is now in a new function called
XLogReadPage(). XLogReadPage() is now responsible for executing
restore_command, launching walreceiver, and waiting for new WAL to arrive
from primary, as required.

This also changes the life cycle of walreceiver. When launched, it now only
tries to connect to the master once, and exits if the connection fails, or
is lost during streaming for any reason. The startup process detects the
death, and re-launches walreceiver if necessary.
2010-01-27 15:27:51 +00:00
config Make configure check the version of Perl we're building with, and reject 2010-01-07 01:41:11 +00:00
contrib Rewrite dblink_record_internal() and dblink_fetch() to use a tuplestore 2010-01-24 22:19:38 +00:00
doc Fix typo. 2010-01-27 13:03:17 +00:00
src Make standby server continuously retry restoring the next WAL segment with 2010-01-27 15:27:51 +00:00
COPYRIGHT Update copyright for the year 2010. 2010-01-02 16:58:17 +00:00
GNUmakefile.in Build bzip2 tarball in dist target as well 2009-11-03 21:28:10 +00:00
Makefile Revert brainfart: Of course the wildcard only works in GNU make itself. 2009-12-23 19:42:15 +00:00
README Point to our download URL, rather than listing interface in the README 2008-05-06 22:02:12 +00:00
README.CVS Fix the makefiles to fail cleanly if Perl is needed but not present. This 2009-06-23 03:46:00 +00:00
aclocal.m4 Add new auto-detection of thread flags. 2004-04-23 18:15:55 +00:00
configure Re-order configure tests to reflect the fact that the code generated for 2010-01-16 19:50:26 +00:00
configure.in Re-order configure tests to reflect the fact that the code generated for 2010-01-16 19:50:26 +00:00

README

PostgreSQL Database Management System
=====================================
  
This directory contains the source code distribution of the PostgreSQL
database management system.

PostgreSQL is an advanced object-relational database management system
that supports an extended subset of the SQL standard, including
transactions, foreign keys, subqueries, triggers, user-defined types
and functions.  This distribution also contains C language bindings.

PostgreSQL has many language interfaces, many of which are listed here:

	http://www.postgresql.org/download

See the file INSTALL for instructions on how to build and install
PostgreSQL.  That file also lists supported operating systems and
hardware platforms and contains information regarding any other
software packages that are required to build or run the PostgreSQL
system.  Changes between all PostgreSQL releases are recorded in the
file HISTORY.  Copyright and license information can be found in the
file COPYRIGHT.  A comprehensive documentation set is included in this
distribution; it can be read as described in the installation
instructions.

The latest version of this software may be obtained at
http://www.postgresql.org/download/.  For more information look at our
web site located at http://www.postgresql.org/.