Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o
Дата
Msg-id 20210809173453.6fugm2z7k6uaztld@alap3.anarazel.de
обсуждение исходный текст
Ответ на Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-committers
Hi,

On 2021-08-09 11:46:30 -0400, Robert Haas wrote:
> I think that subsystems like "memory" and "files" really ought to be
> the lowest-level things we have, and should be shut down last.

I don't disagree with that - but there's a difference between having that as
an abstract goal, and having it a dependency of committing somebodies patch.


> Stuff like "send a message to the stats collector" seems like a higher level
> thing that may require those lower-level facilities in order to operate, and
> must therefore be shut down first.

Yep.


> Maybe some subsystems need to be divided into upper and lower levels to make
> this work, or, well, I don't know, something else.

That's what I ended up doing, right? There's now InitFileAccess() and
InitTemporaryFileAccess().


> But I'm deeply suspicious that lifting stuff like this to the front of the
> shutdown sequence is just papering over the problem, and not actually
> solving it.

If you have a concrete proposal that you think makes sense to tie shared
memory stats to, I'm happy to entertain it. One main motivator for b406478b87e
etc was to allow rejiggering things like this more easily.

Greetings,

Andres Freund



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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Last-minute updates for release notes.