Massive overhaul of pg_dump: make use of dependency information from
Tom Lane <tgl@sss.pgh.pa.us>
Massive overhaul of pg_dump: make use of dependency information from pg_depend to determine a safe dump order. Defaults and check constraints can be emitted either as part of a table or domain definition, or separately if that's needed to break a dependency loop. Lots of old half-baked code for controlling dump order removed.
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/ref/pg_restore.sgml | modified | +1 −55 |
| src/bin/pg_dump/common.c | modified | +378 −227 |
| src/bin/pg_dump/Makefile | modified | +4 −4 |
| src/bin/pg_dump/pg_backup_archiver.c | modified | +138 −410 |
| src/bin/pg_dump/pg_backup_archiver.h | modified | +14 −18 |
| src/bin/pg_dump/pg_backup_custom.c | modified | +7 −7 |
| src/bin/pg_dump/pg_backup_files.c | modified | +4 −4 |
| src/bin/pg_dump/pg_backup.h | modified | +17 −21 |
| src/bin/pg_dump/pg_backup_null.c | modified | +2 −2 |
| src/bin/pg_dump/pg_backup_tar.c | modified | +4 −4 |
| src/bin/pg_dump/pg_dump.c | modified | +2919 −2453 |
| src/bin/pg_dump/pg_dump.h | modified | +210 −66 |
| src/bin/pg_dump/pg_dump_sort.c | added | +727 −0 |
| src/bin/pg_dump/pg_restore.c | modified | +2 −30 |