Re: Adding Unix domain socket path and port topg_stat_get_wal_senders()

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: Adding Unix domain socket path and port topg_stat_get_wal_senders()
Дата
Msg-id 20190412043939.GL2144@paquier.xyz
обсуждение исходный текст
Ответ на Re: Adding Unix domain socket path and port to pg_stat_get_wal_senders()  (Euler Taveira <euler@timbira.com.br>)
Ответы Re: Adding Unix domain socket path and port to pg_stat_get_wal_senders()  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Adding Unix domain socket path and port to pg_stat_get_wal_senders()  (Euler Taveira <euler@timbira.com.br>)
Список pgsql-hackers
On Thu, Apr 11, 2019 at 10:19:01PM -0300, Euler Taveira wrote:
> application_name. I'm not sure if it solves your complain but Peter
> committed a patch [1] for v12 that distinguishes replicas in the same
> host via cluster_name.

Let's be honest, this is just a workaround.

> Socket has different semantic from TCP/UDP. We can't add socket
> information into client_addr unless we are prepared to break this view
> (client_addr has type inet and it would be necessary to change it to
> text). It could break a lot of applications.

client_addr does not seem the right place to store this information,
and it is already documented for years that NULL is used when using a
Unix socket.  But I think that we could change *client_hostname* so as
the path name is reported instead of NULL when connecting through a
Unix domain socket, and there is no need to switch the field type for
that.

I agree with Ishii-san that it would be nice to close the gap here.
For pg_stat_wal_receiver, please note that sender_host reports
correctly the domain path when connecting locally.
--
Michael

Вложения

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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: How to include the header files effectively
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: setLastTid() and currtid()