Re: [RFC] Extend namespace of valid guc names

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [RFC] Extend namespace of valid guc names
Date: 2013-09-06 22:41:58
Message-ID: CA+TgmoZV3YjEtvZV_gbe7mRzLN4mKiDt5K16cnJ44ddnVU87DQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Sep 6, 2013 at 6:31 PM, Andres Freund <andres(at)2ndquadrant(dot)com> wrote:
> On 2013-09-06 14:48:33 -0400, Tom Lane wrote:
>> Andres Freund <andres(at)2ndquadrant(dot)com> writes:
>> > On 2013-09-06 10:13:23 -0400, Tom Lane wrote:
>> >> Well, if you feel an absolute compulsion to make them consistent, I'd
>> >> go with making SET disallow creation of variables with names the file
>> >> parser wouldn't recognize. But why is it such a bad thing if SET can
>> >> do that?
>>
>> > Also, ALTER SYSTEM SET is going to need a similar restriction as well,
>> > otherwise the server won't restart although the GUCs pass validation...
>>
>> Well, sure, but I would think that ALTER SYSTEM SET should be constrained
>> to only set known GUCs, not invent new ones on the fly.
>
> Hm. That sounds inconvenient to me. Consider something like configuring
> the system to use auto_explain henceforth.
> ALTER SYSTEM SET shared_preload_libraries = 'auto_explain';
> ALTER SYSTEM SET auto_explain.log_min_duration = 100;
>
> It seems weird to forbid doing that and requiring a manual LOAD when we
> don't do so for normal SETs. I can live with the restriction if we
> decide it's a good idea, I just wouldn't appreciate it.

I'm with Tom on this one: I think this will save more pain than it causes.

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2013-09-06 22:43:47 Re: Custom Plan node
Previous Message Andres Freund 2013-09-06 22:31:10 Re: [RFC] Extend namespace of valid guc names