Re: Automatic Client Failover - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: Automatic Client Failover
Date
Msg-id 200808151624.m7FGOUM20186@momjian.us
Whole thread Raw
In response to Automatic Client Failover  (Simon Riggs <simon@2ndquadrant.com>)
Responses Re: Automatic Client Failover  (Simon Riggs <simon@2ndQuadrant.com>)
List pgsql-hackers
Simon Riggs wrote:
> When primary server fails, it would be good if the clients connected to
> the primary knew to reconnect to the standby servers automatically.
> 
> We might want to specify that centrally and then send the redirection
> address to the client when it connects. Sounds like lots of work though.
> 
> Seems fairly straightforward to specify a standby connection service at
> client level: .pgreconnect, or pgreconnect.conf
> No config, then option not used.
> 
> Would work with various forms of replication.
> 
> Implementation would be to make PQreset() try secondary connection if
> the primary one fails to reset. Of course you can program this manually,
> but the feature is that you wouldn't need to, nor would you need to
> request changes to 27 different interfaces either.

I assumed share/pg_service.conf would help in this regard;  place the
file on a central server and modify that so everyone connects to another
server. Perhaps we could even add round-robin functionality to that.

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + If your life is a hard drive, Christ can be your backup. +


pgsql-hackers by date:

Previous
From: Martijn van Oosterhout
Date:
Subject: Re: modifying views
Next
From: Andrew Dunstan
Date:
Subject: Re: modifying views