forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit65aaed2
committed
Account for TOAST data while scheduling parallel dumps.
In parallel mode, pg_dump tries to order the table-data-dumpingjobs with the largest tables first. However, it was onlyconsulting the pg_class.relpages value to determine table size.This ignores TOAST data, and so we could make poor schedulingdecisions in cases where some large tables are mostly TOASTeddata while others have very little. To fix, add in the relpagesvalue for the TOAST table as well.This patch also fixes a potential integer-overflow issue thatcould result in poor scheduling on machines where off_t isonly 32 bits wide. Such platforms are probably extinct in thewild, but we do still nominally support them, so repair.Per complaint from Hans Buschmann.Discussion:https://postgr.es/m/7d7eb6128f40401d81b3b7a898b6b4de@W2012-02.nidsa.loc1 parentbe85727 commit65aaed2
2 files changed
+27
-9
lines changedLines changed: 26 additions & 9 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2467 | 2467 |
| |
2468 | 2468 |
| |
2469 | 2469 |
| |
2470 |
| - | |
| 2470 | + | |
| 2471 | + | |
| 2472 | + | |
2471 | 2473 |
| |
2472 | 2474 |
| |
2473 | 2475 |
| |
2474 | 2476 |
| |
2475 | 2477 |
| |
2476 | 2478 |
| |
| 2479 | + | |
| 2480 | + | |
| 2481 | + | |
| 2482 | + | |
| 2483 | + | |
| 2484 | + | |
| 2485 | + | |
| 2486 | + | |
| 2487 | + | |
| 2488 | + | |
| 2489 | + | |
2477 | 2490 |
| |
2478 | 2491 |
| |
2479 | 2492 |
| |
| |||
6254 | 6267 |
| |
6255 | 6268 |
| |
6256 | 6269 |
| |
| 6270 | + | |
6257 | 6271 |
| |
6258 | 6272 |
| |
6259 | 6273 |
| |
| |||
6303 | 6317 |
| |
6304 | 6318 |
| |
6305 | 6319 |
| |
| 6320 | + | |
6306 | 6321 |
| |
6307 | 6322 |
| |
6308 | 6323 |
| |
| |||
6459 | 6474 |
| |
6460 | 6475 |
| |
6461 | 6476 |
| |
6462 |
| - | |
6463 |
| - | |
6464 | 6477 |
| |
6465 | 6478 |
| |
6466 | 6479 |
| |
6467 | 6480 |
| |
6468 |
| - | |
6469 |
| - | |
6470 |
| - | |
6471 |
| - | |
6472 |
| - | |
| 6481 | + | |
| 6482 | + | |
| 6483 | + | |
| 6484 | + | |
6473 | 6485 |
| |
6474 | 6486 |
| |
6475 | 6487 |
| |
| |||
6520 | 6532 |
| |
6521 | 6533 |
| |
6522 | 6534 |
| |
| 6535 | + | |
6523 | 6536 |
| |
6524 | 6537 |
| |
6525 | 6538 |
| |
| |||
6581 | 6594 |
| |
6582 | 6595 |
| |
6583 | 6596 |
| |
| 6597 | + | |
| 6598 | + | |
| 6599 | + | |
| 6600 | + | |
6584 | 6601 |
| |
6585 | 6602 |
| |
6586 | 6603 |
| |
| |||
10407 | 10424 |
| |
10408 | 10425 |
| |
10409 | 10426 |
| |
10410 |
| - | |
| 10427 | + | |
10411 | 10428 |
| |
10412 | 10429 |
| |
10413 | 10430 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
315 | 315 |
| |
316 | 316 |
| |
317 | 317 |
| |
| 318 | + | |
318 | 319 |
| |
319 | 320 |
| |
320 | 321 |
| |
|
0 commit comments
Comments
(0)