Re: libpq host/hostaddr/conninfo inconsistencies - Mailing list pgsql-hackers

From Robert Haas
Subject Re: libpq host/hostaddr/conninfo inconsistencies
Date
Msg-id CA+TgmoZjoLQOmrAZPBGWZUGWOzeWvXu3v=FFtOAt8H3dCUV+vw@mail.gmail.com
Whole thread Raw
In response to Re: libpq host/hostaddr/conninfo inconsistencies  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: libpq host/hostaddr/conninfo inconsistencies  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Thu, Feb 21, 2019 at 10:33 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Sure, you only need it if you want to bypass DNS lookup, but if you
> do that, you don't necessarily need to give "host" as well.  Changing
> the documentation to imply that you do would not be an improvement.

From my point of view, the issue here is that the way the
documentation is written right now tends to lead people to believe
that if they have a host name, they must pass it via host, and if they
have an IP address, they must pass it via hostaddr.  Thus pgAdmin 3,
at least, had code to check whether the input looked like an IP
address and put it into one field or the other accordingly.  And
that's stupid.

My feeling is that it doesn't really matter whether people think that
both host and hostaddr are required.  What's more important is that
they understand that whatever form of host identifier they've got can
be put in host, and that hostaddr doesn't normally need to be set at
all.  That's less clear than it could be at present.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-hackers by date:

Previous
From: Kuntal Ghosh
Date:
Subject: Re: COPY FREEZE and setting PD_ALL_VISIBLE/visibility map bits
Next
From: Tom Lane
Date:
Subject: Re: libpq host/hostaddr/conninfo inconsistencies