Re: Parsing config files in a directory

Поиск
Список
Период
Сортировка
От Josh Berkus
Тема Re: Parsing config files in a directory
Дата
Msg-id 4AE7BD34.7090103@agliodbs.com
обсуждение исходный текст
Ответ на Re: Parsing config files in a directory  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: Parsing config files in a directory  (Greg Stark <gsstark@mit.edu>)
Re: Parsing config files in a directory  (Robert Haas <robertmhaas@gmail.com>)
Re: Parsing config files in a directory  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Re: Parsing config files in a directory  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
On 10/27/09 8:24 PM, Robert Haas wrote:
> read the old postgresql.conf and
> write it back out to a new file line by line.  If, in the process of
> doing this, you find a setting for the variable you're trying to
> change, then write out the new line in place of the original line. 

You've hit the problem on the head right there.  The requirement to do
something like that is *exactly* the problem which makes writing
config-management tools hard/impossible.

If you require that a tool (or SET PERISTENT) parse through a file in
order to change one setting, then you've just doubled or tripled the
code size of the tool, as well as added a host of failure conditions
which wouldn't have existed otherwise.

You're hearing from the people who are working on tools: requiring that
any tool parse a hand-written config file is a non-starter.

--Josh Berkus


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

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Where's the docs?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Where's the docs?