Re: pgsql: Prevent instability in contrib/pageinspect's regression test.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pgsql: Prevent instability in contrib/pageinspect's regression test.
Дата
Msg-id 3264594.1669061535@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: pgsql: Prevent instability in contrib/pageinspect's regression test.  (Andres Freund <andres@anarazel.de>)
Ответы Re: pgsql: Prevent instability in contrib/pageinspect's regression test.  ("David G. Johnston" <david.g.johnston@gmail.com>)
Re: pgsql: Prevent instability in contrib/pageinspect's regression test.  (Andres Freund <andres@anarazel.de>)
Список pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2022-11-21 12:52:01 -0500, Robert Haas wrote:
>> On Mon, Nov 21, 2022 at 12:35 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>>> Why in the world is get_raw_page() marked as parallel safe?
>>> It clearly isn't, given this restriction.

> It's somewhat sad to add this restriction - I've used get_raw_page() (+
> other functions) to scan a whole database for a bug. IIRC that actually
> did end up using parallelism, albeit likely not very efficiently.
> Don't really have a better idea though.

Me either.

> It may be worth inventing a framework where a function could analyze its
> arguments (presumably via prosupport) to determine the degree of
> parallel safety, but this doesn't seem sufficient reason...

Maybe, but in this example you could only decide you were parallel
safe if the argument is an OID constant, which'd be pretty limiting.

If I were trying to find a better fix I'd be looking for ways for
parallel workers to be able to read the parent's temp tables.
(Perhaps that could tie in with the blue-sky discussion we had
the other day about allowing autovacuum on temp tables??)

            regards, tom lane



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Cleanup: Duplicated, misplaced comment in HeapScanDescData
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Add 64-bit XIDs into PostgreSQL 15