From: | Victor Wagner <vitus(at)wagner(dot)pp(dot)ru> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Proposal: Implement failover on libpq connect level. |
Date: | 2015-08-19 17:34:48 |
Message-ID: | 20150819173448.GA4767@wagner.pp.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-jdbc |
On 2015.08.20 at 00:17:35 +0900, Tatsuo Ishii wrote:
> > But once connection is established, each client works with one
> > server (at least until communication failure occurs and it would call
> > PQreset. In this case it has to reprepare statements anyway).
>
> One downside of this is, if one of the standby servers is not
> responding, every time clients will be blocked by the server before
> giving up the connection trial. This could last for hours (for
This shouldn't happen. My proposal was to connect all servers
simultaneously, and then use that connection which would be established
first closing other ones
Even if we wouldn't do so (to properly randomize server load or to be
compatible with jdbc), there is connection_timeout parameter, so
client wouldn't seat and just wait for hours while system TCP/IP stack
trying to connect nonexistent server.
> example, the network cable is plugged out). I think round robin DNS is
> better because the DNS server will drop the entry corresponding broken
DNS server wouldn't drop anything unless explicitely told so (by
administrator or by some watchdog software which is able to talk
nsupdate protocol).
And not everyone database owner has control on his own domain.
Moreover, DNS is distributed system with agressive caching. If our
system is not local, DNS records for non-existing server would be cached
by DNS servers of client's internet provider.
From | Date | Subject | |
---|---|---|---|
Next Message | jacques klein | 2015-08-19 17:45:47 | Re: how to write/setup a C trigger function in a background worker |
Previous Message | Qingqing Zhou | 2015-08-19 17:32:25 | Re: Our trial to TPC-DS but optimizer made unreasonable plan |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2015-08-19 18:11:31 | Re: Proposal: Implement failover on libpq connect level. |
Previous Message | David Fetter | 2015-08-19 15:40:41 | Re: Proposal: Implement failover on libpq connect level. |