Re: Re: libpq host/hostaddr/conninfo inconsistencies

David Steele <david@pgmasters.net>

From: David Steele <david@pgmasters.net>
To: Fabien COELHO <coelho@cri.ensmp.fr>, Tom Lane <tgl@sss.pgh.pa.us>
Cc: Robert Haas <robertmhaas@gmail.com>, Andres Freund <andres@anarazel.de>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2019-03-21T17:54:55Z
Lists: pgsql-hackers
On 2/22/19 9:44 PM, Fabien COELHO wrote:
> 
> Hmmm, I do not buy the typing argument: "host" is actually for 
> everything, including directories. I do not think that adding "hostdir" 
> would be desirable.
> 
>> In any case, the existing doco never comes out and states either
>> rule set in so many words.  Maybe it should.

Personally I like the second and third edit from Robert's patch, but not 
the first one.  I'm having a hard time seeing why you would specify host 
*and* hostaddr as this seems to imply.

I also agree with Fabien's comment that host can be a path -- it's 
really a path to a socket file, but it's certainly not a host name or IP 
address.  Perhaps that should be called out explicitly.

Regards,
-- 
-David
david@pgmasters.net


Commits

  1. libpq docs: be clearer about conninfo's 'hostaddr'

  2. psql: Show IP address in \conninfo