Re: [Patch] Make pg_checksums skip foreign tablespace directories

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [Patch] Make pg_checksums skip foreign tablespace directories
Дата
Msg-id 20200225023309.GB17153@paquier.xyz
обсуждение исходный текст
Ответ на Re: [Patch] Make pg_checksums skip foreign tablespace directories  (Bernd Helmle <mailings@oopsware.de>)
Ответы Re: [Patch] Make pg_checksums skip foreign tablespace directories  (Bernd Helmle <mailings@oopsware.de>)
Список pgsql-hackers
On Mon, Feb 24, 2020 at 01:11:10PM +0100, Bernd Helmle wrote:
> The other makes scan_directories() complicated to read and special
> cases just a single directory in an otherwise more or less generic
> function.  E.g. it makes me uncomfortable if we get a pg_tblspc
> somewhere else than PGDATA (if someone managed to create such a
> directory in a foreign tablespace location for example), so we should
> maintain an additional check if we really operate on the pg_tblspc we
> have to. That was the reason(s) i've moved it into a separate function.

We are just discussing about the code path involving scanning a
directory, so that does not seem that bad to me.  I really think that
we should avoid duplicating the same logic around, and that we should
remain consistent with non-directory entries in those paths,
complaining with a proper failure if extra, unwanted files are
present.
--
Michael

Вложения

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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: Ought to use heap_multi_insert() for pg_attribute/dependinsertions?
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: client-side fsync() error handling