Re: Advice regarding configuration parameters - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Advice regarding configuration parameters
Date
Msg-id 383.1076083269@sss.pgh.pa.us
Whole thread Raw
In response to Re: Advice regarding configuration parameters  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: Advice regarding configuration parameters  (Joe Conway <mail@joeconway.com>)
List pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:
> Am Freitag, 6. Februar 2004 10:27 schrieb Thomas Hallgren:
>> I would like some configuration parameters to Pl/Java and I would like some
>> advice. Where should they go?
>> 
>> 1. Something similar to postgresql.conf (it's not extendable though, is
>> it?)

> No, it is not.

In principle it could be --- the mechanisms already exist in guc.c to
permit outside agents to add variables.  The difficulty in having a PL
handler add such variables is that there is no good way to get the
handler to run before postgresql.conf is scanned for the first time,
and if it isn't then GUC will error out on the "unknown" variable name.

> I have been thinking for some time about a generic mechanism to
> configure procedural languages.  It could be a text array in
> pg_language that you could fill at will.

If we had a mechanism that allowed "unrecognized" variable names in
postgresql.conf to be saved and reprocessed later, we could allow PLs
and other dynamically-loaded libraries to be configured via ordinary GUC
variables, which would be much nicer than a special-purpose mechanism.
Of course this would have a negative impact on the ability to detect
plain old misspellings in the config file.  Perhaps we could have a
compromise that says that specially formed variable names, maybe like
"pljava::myparam", are allowed to escape the normal error check.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: Advice regarding configuration parameters
Next
From: Jan Wieck
Date:
Subject: Re: [pgsql-hackers-win32] Sync vs. fsync during checkpoint