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

2022-11-23 Thread Greg Stark
On Mon, 21 Nov 2022 at 15:01, Andres Freund wrote: > > 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

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

2022-11-21 Thread Tom Lane
Andres Freund writes: > On 2022-11-21 15:12:15 -0500, Tom Lane wrote: >> 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

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

2022-11-21 Thread Andres Freund
Hi, On 2022-11-21 15:12:15 -0500, Tom Lane wrote: > 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

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

2022-11-21 Thread David G. Johnston
On Mon, Nov 21, 2022 at 1:12 PM Tom Lane wrote: > Andres Freund writes: > > On 2022-11-21 12:52:01 -0500, Robert Haas wrote: > >> On Mon, Nov 21, 2022 at 12:35 PM Tom Lane wrote: > >>> Why in the world is get_raw_page() marked as parallel safe? > >>> It clearly isn't, given this restriction. >

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

2022-11-21 Thread Tom Lane
Andres Freund writes: > On 2022-11-21 12:52:01 -0500, Robert Haas wrote: >> On Mon, Nov 21, 2022 at 12:35 PM Tom Lane 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

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

2022-11-21 Thread Andres Freund
Hi, On 2022-11-21 12:52:01 -0500, Robert Haas wrote: > On Mon, Nov 21, 2022 at 12:35 PM Tom Lane wrote: > > I wrote: > > > Andres Freund writes: > > >> Looks like a chunk of the buildfarm doesn't like this - presumably > > >> because > > >> they use force_parallel_mode = regress. Seems ok to

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

2022-11-21 Thread Tom Lane
I wrote: > I'll check to see if any sibling functions have the same issue, > and push a patch to adjust them. > Presumably the parallel labeling has to be fixed as far back as > it's marked that way (didn't look). Maybe we should push the > test change further back too, just to exercise this.

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

2022-11-21 Thread Tom Lane
Robert Haas writes: > On Mon, Nov 21, 2022 at 12:35 PM Tom Lane wrote: >> Hmm, so the problem is: >> >> SELECT octet_length(get_raw_page('test1', 'main', 0)) AS main_0; >> ERROR: cannot access temporary tables during a parallel operation >> >> Why in the world is get_raw_page() marked as

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

2022-11-21 Thread Robert Haas
On Mon, Nov 21, 2022 at 12:35 PM Tom Lane wrote: > I wrote: > > Andres Freund writes: > >> Looks like a chunk of the buildfarm doesn't like this - presumably because > >> they use force_parallel_mode = regress. Seems ok to just force that to off > >> in > >> this test? > > > Ugh ... didn't

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

2022-11-21 Thread Tom Lane
I wrote: > Andres Freund writes: >> Looks like a chunk of the buildfarm doesn't like this - presumably because >> they use force_parallel_mode = regress. Seems ok to just force that to off in >> this test? > Ugh ... didn't occur to me to try that. I'll take a look. Hmm, so the problem is: