Re: Warn when parallel restoring a custom dump without data offsets

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: David Gilman <davidgilman1(at)gmail(dot)com>
Cc: Justin Pryzby <pryzby(at)telsasoft(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Warn when parallel restoring a custom dump without data offsets
Date: 2020-05-20 14:48:30
Message-ID: 25161.1589986110@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

David Gilman <davidgilman1(at)gmail(dot)com> writes:
>> I think the PG11
>> commit you mentioned (548e5097) happens to make some databases fail in
>> parallel restore that previously worked (I didn't check).

> Correct, if you do the bisect around that yourself you'll see
> pg_restore start failing with the expected "possibly due to
> out-of-order restore request" on offset-less dumps.

Yeah. Now, the whole point of that patch was to decouple the restore
order from the dump order ... but with an offset-less dump file, we
can't do that, or at least the restore order is greatly constrained.
I wonder if it'd be sensible for pg_restore to use a different parallel
scheduling algorithm if it notices that the input lacks offsets.
(There could still be some benefit from parallelism, just not as much.)
No idea if this is going to be worth the trouble, but it probably
is worth looking into.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2020-05-20 16:32:34 Re: factorial function/phase out postfix operators?
Previous Message Tom Lane 2020-05-20 14:39:18 Re: Extensions not dumped when --schema is used