]> granicus.if.org Git - postgresql/commit
Modify parallel pg_restore to track pending and ready items by means of
authorTom Lane <tgl@sss.pgh.pa.us>
Fri, 7 Aug 2009 22:48:34 +0000 (22:48 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Fri, 7 Aug 2009 22:48:34 +0000 (22:48 +0000)
commitf033f6d28b014ff21c8ed250f55062c2fb1b12e8
treed2ad3729f10178b9343b19ba6a0f7d415803c3d6
parent05f43650fcf008a12dd92db4d1ae15c43046e62c
Modify parallel pg_restore to track pending and ready items by means of
two new lists, rather than repeatedly rescanning the main TOC list.
This avoids a potential O(N^2) slowdown, although you'd need a *lot*
of tables to make that really significant; and it might simplify future
improvements in the scheduling algorithm by making the set of ready
items more easily inspectable.  The original thought that it would
in itself result in a more efficient job dispatch order doesn't seem
to have been borne out in testing, but it seems worth doing anyway.
src/bin/pg_dump/pg_backup_archiver.c
src/bin/pg_dump/pg_backup_archiver.h