Tom Lane wrote:
> What do you think of the idea of suppressing the "unknown variable"
> error for some class of variable names?
I like it. I wonder if we ought to have a way to "register" valid
classes? Maybe a new guc variable in the form of a list of valid
classes. So something like:
custom_variable_class = 'plr,pljava'
plr::foo = '/usr/lib/R'
pljava::baz = 1
plruby::var = true <== this one would generate an error
> If we had agreement on doing that then I think the rest would be
> pretty simple. After a few moments' thought I like the following
> sketch:
[good implementation ideas]
> This scheme could not handle add-on GUC variables with some of the
> odder flags, such as GUC_LIST_INPUT, since the correct flag values
> wouldn't be known when the input is first seen.
I think this is OK.
> And we'd have to think a little about how to handle variable values
> that are discovered to be erroneous when we try to assign them to the
> variable --- probably we can just drop them, but does that make the
> semantics weird at all?
Maybe we can require a default value as a parameter to
add_guc_variable() and use that?
Joe