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
Date: 2016-09-08T11:24:20Z
Lists: pgsql-hackers
Attachments
- libpq-failover-8.patch (text/x-patch) patch
On Tue, 6 Sep 2016 07:58:28 +0530 Mithun Cy <mithun.cy@enterprisedb.com> wrote: > On Mon, Sep 5, 2016 at 4:33 PM, Aleksander Alekseev < > a.alekseev@postgrespro.ru> wrote: > >After a brief examination I've found following ways to improve the > >patch. > Adding to above comments. > I'm sending new version of patch. I've replaced readonly option with target_server_type (with JDBC compatibility alias targetServerType), use logic of setting defaults based on number of hosts in the connect string instead of complicated condition in the state machine, added checks for return values of memory allocation function. Also, I've solved pg_usleep problem by linking pgsleep.c into libpq along with some other libpgport objects which are already linked there. Thus client applications don't need to link with libpgport and libpq shared library is self-containted.
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