Re: Idea about better configuration options for sort memory - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Idea about better configuration options for sort memory
Date
Msg-id 26290.1075685026@sss.pgh.pa.us
Whole thread Raw
In response to Re: Idea about better configuration options for sort memory  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: Idea about better configuration options for sort memory  (Gaetano Mendola <mendola@bigfoot.com>)
Re: Idea about better configuration options for sort memory  (Joe Conway <mail@joeconway.com>)
Re: Idea about better configuration options for sort memory  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Tom Lane wrote:
>> BTW, I am going to look at whether GUC can be persuaded to continue to
>> allow "sort_mem" as an alternate name, if we rename it.  That would
>> alleviate most of the backward-compatibility issues of changing such
>> a well-known parameter name.

> Good. It is not like we have a huge namespace limitation in there.  I
> wonder if we could cost it as a list of string pointers, null
> terminated.

After looking at the code a bit, I think the simplest solution is for
find_option to look in a separate mapping table (mapping from old to new
option name) if it doesn't find the given name in the main table.  This
would make lookup of "old" names a shade slower than "preferred" names,
but that doesn't seem like a problem.

With this approach, old GUC names would be recognized in SHOW and SET
commands, as well as the other ways you can set a variable by name
(postgresql.conf, ALTER USER SET, etc).  But only the new names would
appear in SHOW ALL or the pg_settings view.  Does that seem OK?
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Andrew Dunstan"
Date:
Subject: Re: fork/exec
Next
From: alban
Date:
Subject: Re: SPI find backend id (novice)