Re: [HACKERS] Revisiting NAMEDATALEN

Поиск
Список
Период
Сортировка
Искать
От
Robert Haas
Тема
Re: [HACKERS] Revisiting NAMEDATALEN
Дата
Msg-id
CA+TgmoZ7vtzX=Ry2TYLrAborWUxwUWbHCAO13wpPdsKr=iy6rQ@mail.gmail.com
Ответ на
Список
Дерево обсуждения
[HACKERS] Revisiting NAMEDATALEN Emrul <emrul@emrul.com>
Re: [HACKERS] Revisiting NAMEDATALEN Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] Revisiting NAMEDATALEN Emrul <emrul@emrul.com>
Re: [HACKERS] Revisiting NAMEDATALEN Mark Dilger <hornschnorter@gmail.com>
Re: [HACKERS] Revisiting NAMEDATALEN Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] Revisiting NAMEDATALEN Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] Revisiting NAMEDATALEN Bruce Momjian <bruce@momjian.us>
Re: [HACKERS] Revisiting NAMEDATALEN "Joshua D. Drake" <jd@commandprompt.com>
Re: [HACKERS] Revisiting NAMEDATALEN Emrul <emrul@emrul.com>
On Fri, Jul 7, 2017 at 5:53 AM, Emrul  wrote:
> Tom, thank you for that pointer.  I get now that it is not free and therefore
> why its not something that should be changed by default.
>
> I guess the problem is 'build your own copy' (i.e. compiling from source) is
> something that sends most DB teams running into the hills.
>
> A solution might be to make NAMEDATALEN configurable without having to
> recompile source (perhaps a config variable or an initdb parameter). When I
> have some free time I will investigate whether this is doable.

Well, it wouldn't be free.  The problem is:

typedef struct nameData
{       char            data[NAMEDATALEN];
} NameData;

If it were not a compile-time constant, every bit of code that uses
NameData (or otherwise depends on NAMEDATALEN being constant) would
have to be changed.  That would be invasive and likely have at least a
minor performance cost.

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


В списке pgsql-hackers по дате отправления
От: Michael Meskes
Дата:
От: Fabien COELHO
Дата:
FAQ