postgresql/src/bin/pg_dump
Andres Freund 471a7af585 Ensure consistent sort order of large objects in pg_dump.
The primary purpose of this commit is to ensure pg_upgrade tests yield
comparable dumps pre/post upgrade, which got broken by 12a53c732 /
578b229718, as the order in pg_largeobject_metadata is likely to
differ pre/post upgrade.

It also seems like a generally good idea to make sure such dumps are
comparable, outside of pg_upgrade tests.

LO metadata already was already dumped in an ordered manner as the
metadata is dumped in a well defined order via
sortDumpableObjectsByTypeName() and sortDumpableObjects(). But large
object data is currently not tracked via that mechanism.

As Tom points out it seems possible that at some point dumpBlobs() was
assumed to dump out objects in a well defined order, due to the use of
DISTINCT, which at that time only was done using sorting.

Per complaint from Andrew Dunstan and discussion with him and Tom
Lane.

Author: Andres Freund
Discussion: https://postgr.es/m/2735.1543333649@sss.pgh.pa.us
2018-11-27 12:16:55 -08:00
..
po Translation updates 2018-05-21 12:29:52 -04:00
t Fix pg_upgrade for oid removal. 2018-11-26 14:37:08 -08:00
.gitignore Clean up after pg_dump test runs. 2016-05-06 22:28:01 -04:00
common.c Code review for pg_dump's handling of ALTER INDEX ATTACH PARTITION. 2018-08-28 19:33:04 -04:00
compress_io.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
compress_io.h Update copyright for 2018 2018-01-02 23:30:12 -05:00
dumputils.c Further fixes for quoted-list GUC values in pg_dump and ruleutils.c. 2018-07-31 13:00:14 -04:00
dumputils.h Further fixes for quoted-list GUC values in pg_dump and ruleutils.c. 2018-07-31 13:00:14 -04:00
Makefile Prevent accidental linking of system-supplied copies of libpq.so etc. 2018-04-03 16:26:05 -04:00
nls.mk Translation updates 2018-05-21 12:29:52 -04:00
parallel.c Ensure schema qualification in pg_restore DISABLE/ENABLE TRIGGER commands. 2018-08-17 17:12:33 -04:00
parallel.h Update copyright for 2018 2018-01-02 23:30:12 -05:00
pg_backup_archiver.c Remove WITH OIDS support, change oid catalog column visibility. 2018-11-20 16:00:17 -08:00
pg_backup_archiver.h Remove WITH OIDS support, change oid catalog column visibility. 2018-11-20 16:00:17 -08:00
pg_backup_custom.c Improve parallel scheduling logic in pg_dump/pg_restore. 2018-09-14 17:31:51 -04:00
pg_backup_db.c Empty search_path in Autovacuum and non-psql/pgbench clients. 2018-02-26 07:39:44 -08:00
pg_backup_db.h Add some const decorations to prototypes 2017-11-10 13:38:57 -05:00
pg_backup_directory.c Improve parallel scheduling logic in pg_dump/pg_restore. 2018-09-14 17:31:51 -04:00
pg_backup_null.c Reduce excessive dereferencing of function pointers 2017-09-07 13:56:09 -04:00
pg_backup_tar.c Implement %m in src/port/snprintf.c, and teach elog.c to rely on that. 2018-09-26 13:31:56 -04:00
pg_backup_tar.h Fix tar files emitted by pg_dump and pg_basebackup to be POSIX conformant. 2012-09-28 15:19:15 -04:00
pg_backup_utils.c Update copyright for 2018 2018-01-02 23:30:12 -05:00
pg_backup_utils.h Update copyright for 2018 2018-01-02 23:30:12 -05:00
pg_backup.h Remove WITH OIDS support, change oid catalog column visibility. 2018-11-20 16:00:17 -08:00
pg_dump_sort.c Improve parallel scheduling logic in pg_dump/pg_restore. 2018-09-14 17:31:51 -04:00
pg_dump.c Ensure consistent sort order of large objects in pg_dump. 2018-11-27 12:16:55 -08:00
pg_dump.h Remove WITH OIDS support, change oid catalog column visibility. 2018-11-20 16:00:17 -08:00
pg_dumpall.c Remove deprecated abstime, reltime, tinterval datatypes. 2018-10-11 11:59:15 -07:00
pg_restore.c Consolidate cross-option checks in pg_restore 2018-10-30 11:38:35 +09:00