Re: pg_dump --split patch

Marko Tiikkaja <pgmail@joh.to>

From: Marko Tiikkaja <pgmail@joh.to>
To: Joel Jacobson <joel@gluefinance.com>
Cc: pgsql-hackers@postgresql.org
Date: 2012-10-22T11:33:42Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. pg_dump: Output functions deterministically sorted

  2. When sorting functions in pg_dump, break ties (same name) by number of arguments

Attachments

Hi,

Now that the (at least as far as I know) last ordering problem in 
pg_dump has been solved [1], I'm going to attempt resurrecting this old 
thread.

It seemed to me that the biggest objections to this patch in the old 
discussions were directed at the implementation, which I have tried to 
improve.  The attached patch implements the actual splitting in a new 
backup format.

The general output scheme looks like this:
    schemaname/OBJECT_TYPES/object_name.sql,

but there are some exceptions.

Overloaded functions are dumped into the same file.  Object names are 
encoded into the POSIX Portable Filename Character Set ([a-z0-9._-]) by 
replacing any characters outside that set with an underscore.

Restoring the dump is supported through an index.sql file containing 
statements which include (through \i) the actual object files in the 
dump directory.

Any thoughts?  Objections on the idea or the implementation?


[1]: 
http://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=7b583b20b1c95acb621c71251150beef958bb603


Regards,
Marko Tiikkaja