Re: fix psql \conninfo & \connect when using hostaddr

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: fix psql \conninfo & \connect when using hostaddr
Дата
Msg-id alpine.DEB.2.21.1906132140090.10845@lancre
обсуждение исходный текст
Ответ на Re: fix psql \conninfo & \connect when using hostaddr  (Noah Misch <noah@leadboat.com>)
Ответы Re: fix psql \conninfo & \connect when using hostaddr  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Список pgsql-hackers
Hello Noah,

>> there is no simple way to know whether hostaddr was set at
>> the libPQ level
>
>> A solution could be to have a PQdoestheconnectionuseshostaddr(conn)
>> function, but I cannot say I'd be thrilled.
>
> PQconninfo() is the official way to retrieve that.

Thanks for the pointer! I did not notice this one. At least the API looks 
better than the one I was suggesting:-)

ISTM that this function could be used to set other parameters, fixing some 
other issues such as ignoring special parameters on reconnections.

Anyway, attached an attempt at implementing the desired behavior wrt 
hostaddr.

-- 
Fabien.
Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Robert Haas
Дата:
Сообщение: REINDEX locking
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: REINDEX locking