postgresql/contrib/pg_upgrade
Tom Lane caddcb8f4b Fix pg_upgrade to handle extensions.
This follows my proposal of yesterday, namely that we try to recreate the
previous state of the extension exactly, instead of allowing CREATE
EXTENSION to run a SQL script that might create some entirely-incompatible
on-disk state.  In --binary-upgrade mode, pg_dump won't issue CREATE
EXTENSION at all, but instead uses a kluge function provided by
pg_upgrade_support to recreate the pg_extension row (and extension-level
pg_depend entries) without creating any member objects.  The member objects
are then restored in the same way as if they weren't members, in particular
using pg_upgrade's normal hacks to preserve OIDs that need to be preserved.
Then, for each member object, ALTER EXTENSION ADD is issued to recreate the
pg_depend entry that marks it as an extension member.

In passing, fix breakage in pg_upgrade's enum-type support: somebody didn't
fix it when the noise word VALUE got added to ALTER TYPE ADD.  Also,
rationalize parsetree representation of COMMENT ON DOMAIN and fix
get_object_address() to allow OBJECT_DOMAIN.
2011-02-09 19:18:08 -05:00
..
.gitignore Convert cvsignore to gitignore, and add .gitignore for build targets. 2010-09-22 12:57:04 +02:00
IMPLEMENTATION Remove useless whitespace at end of lines 2010-11-23 22:34:55 +02:00
Makefile Remove cvs keywords from all files. 2010-09-20 22:08:53 +02:00
TESTING Remove useless whitespace at end of lines 2010-11-23 22:34:55 +02:00
check.c Fix wrong verb in pg_upgrade text message, per Haas. 2011-02-02 16:53:12 -05:00
controldata.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
dump.c Fix pg_upgrade of large object permissions by preserving pg_auth.oid, 2011-01-07 21:59:29 -05:00
exec.c Repair multiple breakage in Windows-specific code for appending '.exe'. 2011-02-02 20:26:43 -05:00
file.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
function.c Fix pg_upgrade to handle extensions. 2011-02-09 19:18:08 -05:00
info.c A toast relid field are no longer needed in pg_upgrade's rel arrays, so 2011-01-10 11:46:02 -05:00
option.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
page.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
pg_upgrade.c Add pg_upgrade comment for why we can't use template1 inheritance for 2011-02-01 12:23:08 -05:00
pg_upgrade.h A toast relid field are no longer needed in pg_upgrade's rel arrays, so 2011-01-10 11:46:02 -05:00
relfilenode.c In pg_upgrade, remove functions that did sequential array scans looking 2011-01-08 13:44:44 -05:00
server.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
tablespace.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
util.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
version.c Stamp copyrights for year 2011. 2011-01-01 13:18:15 -05:00
version_old_8_3.c Clarify pg_upgrade's creation of the map file structure. Also clean 2011-01-05 11:37:08 -05:00