Re: Patch: Implement failover on libpq connect level.
От | Tsunakawa, Takayuki |
---|---|
Тема | Re: Patch: Implement failover on libpq connect level. |
Дата | |
Msg-id | 0A3221C70F24FB45833433255569204D1F63FB5E@G01JPEXMBYT05 обсуждение исходный текст |
Ответ на | Re: Patch: Implement failover on libpq connect level. (Robert Haas <robertmhaas@gmail.com>) |
Ответы |
Re: Patch: Implement failover on libpq connect level.
|
Список | pgsql-hackers |
From: pgsql-hackers-owner@postgresql.org > [mailto:pgsql-hackers-owner@postgresql.org] On Behalf Of Robert Haas > Great, committed. There's still potentially more work to be done here, > because my patch omits some features that were present in Victor's original > submission, like setting the failover timeout, optionally randomizing the > order of the hosts, and distinguishing between master and standby servers; > Victor, or anyone, please feel free to submit separate patches for those > things. The attached patch fixes some bugs and make a clarification for doc. Could you check and test the authentication stuff asI don't have an environment at hand? (1) fe-connect.c There was a memory leak. (2) fe-secure_openssl.c, fe-auth.c GSSAPI/SSPI/SSL authentication requires the target host name, but the code uses conn->pghost which contains a comma-separatedlist of host names. (3) libpq.sgml Added sentences to clarify connect_timeout when it is used with multiple hosts. BTW, let me two questions. Q1: Is there any reason why hostaddr doesn't accept multiple IP addresses? Q2: pg_isready (and hence PQping() family) reports success when one host is alive and other hosts are down. Is this intended? I think this behavior is correct. e.g. host1 is down and host2 is alive. $ pg_isready -h host1,host2 host1,host2:5450 - accepting connections $ echo $? 0 Regards Takayuki Tsunakawa
Вложения
В списке pgsql-hackers по дате отправления: