pg_service.conf file with unknown parameters

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: pg_service.conf file with unknown parameters
Date: 2020-09-11 12:39:51
Message-ID: CABUevEw_RRRgG2uwsO7CD0TQf+Z=oR=S1=QyifV8D_5hatJ=oQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Right now, pg_service.conf returns "syntax error" if it encounters a
parameter it doesn't know about.

This seems user-unfriendly, both in the error message (because it really
isn't a syntax error) and in the behaviour itself (because it doesn't work
when sometimes it should).

For example, if I have a service file with gssencmode=disable set, that
service file cannot be used by a psql client linked against libpq from
version 10. Even if the behavior would be identical (since v10 doesn't have
gssencmode).

Is there a particular reason we (1) refuse unknown parameters in the file,
and (2) call it a "syntax error"?

The documentation just says it's "INI format" file -- though in my
experience most other INI file parsers just ignore extra parameters
included..

//Magnus

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bharath Rupireddy 2020-09-11 12:42:41 Re: Logical Replication - detail message with names of missing columns
Previous Message Ranier Vilela 2020-09-11 11:56:58 Re: Avoid incorrect allocation in buildIndexArray