Re: Patch: Implement failover on libpq connect level.
Victor Wagner <vitus@wagner.pp.ru>
From: Victor Wagner <vitus@wagner.pp.ru>
To: pgsql-hackers@postgresql.org
Cc: Thom Brown <thom@linux.com>
Date: 2016-01-22T19:30:51Z
Lists: pgsql-hackers
Attachments
- libpq-failover-6.patch (text/x-patch) patch
On Tue, 19 Jan 2016 14:34:54 +0000
Thom Brown <thom@linux.com> wrote:
>
> The segfault issue I originally reported now appears to be resolved.
>
> But now I have another one:
>
> psql
> 'postgresql://thom@127.0.0.1:5530,127.0.0.1:5531,127.0.0.1:5532,127.0.0.1:5533/postgres?hostorder=random&readonly=1&failover_timeout=5'
> -c 'show port'
Here is new version of the patch. Now I've reworked hostorder=random and
it seems to work as well as sequential. failover_timeout works too.
I've also found a case when attempt to connect fail when receiving
FATAL message from server which is not properly up yet. So, it is fixed
too.
Addititonally, error messages from all failed connect attempts are not
accumulated now. Only last one is returned.
--
Victor Wagner <vitus@wagner.pp.ru>
Commits
-
libpq: Add target_session_attrs parameter.
- 721f7bd3cbcc 10.0 landed
-
Remove superuser checks in pgstattuple
- fd321a1dfd64 10.0 cited
-
Fix unwanted flushing of libpq's input buffer when socket EOF is seen.
- c405918858c0 9.6.0 cited