aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/async.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2021-12-06 13:23:07 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2021-12-06 13:23:07 -0500
commit65aaed22a849c0763f38f81338a1cad04ffc0e2c (patch)
treec10e02b454efbbe7d0529e90289733f860a20b11 /src/backend/commands/async.c
parentbe85727a3df743a1f7e93b41dd7ac2b667e8ae04 (diff)
downloadpostgresql-65aaed22a849c0763f38f81338a1cad04ffc0e2c.tar.gz
postgresql-65aaed22a849c0763f38f81338a1cad04ffc0e2c.zip
Account for TOAST data while scheduling parallel dumps.
In parallel mode, pg_dump tries to order the table-data-dumping jobs with the largest tables first. However, it was only consulting the pg_class.relpages value to determine table size. This ignores TOAST data, and so we could make poor scheduling decisions in cases where some large tables are mostly TOASTed data while others have very little. To fix, add in the relpages value for the TOAST table as well. This patch also fixes a potential integer-overflow issue that could result in poor scheduling on machines where off_t is only 32 bits wide. Such platforms are probably extinct in the wild, but we do still nominally support them, so repair. Per complaint from Hans Buschmann. Discussion: https://postgr.es/m/7d7eb6128f40401d81b3b7a898b6b4de@W2012-02.nidsa.loc
Diffstat (limited to 'src/backend/commands/async.c')
0 files changed, 0 insertions, 0 deletions