Re: [RFC] Extend namespace of valid guc names

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [RFC] Extend namespace of valid guc names
Дата
Msg-id 14857.1378523977@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [RFC] Extend namespace of valid guc names  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> On Fri, Sep 6, 2013 at 6:31 PM, Andres Freund <andres@2ndquadrant.com> wrote:
>> On 2013-09-06 14:48:33 -0400, Tom Lane wrote:
>>> 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;

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

So far as that example goes, I'm not suggesting that "ALTER SYSTEM SET
auto_explain.log_min_duration" should be forbidden altogether.  I *am*
saying that it should only be allowed when auto_explain is loaded in the
current session, so that we can find out whether the proposed value is
allowed by the module that defines the GUC.

Of course, this is not completely bulletproof, since it will fail if the
defining module changes its mind from time to time about what are valid
values of the GUC :-(.  But promising to restart in the face of that kind
of inconsistency is hopeless.  On the other hand, not checking at all is
just asking for failures.
        regards, tom lane



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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: strange IS NULL behaviour
Следующее
От: Kohei KaiGai
Дата:
Сообщение: Re: Custom Plan node