pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter_e@gmx.net>
To: pgsql-committers@postgresql.org
Subject: pgsql: pg_upgrade: Upgrade sequence data via pg_dump
Date: Mon, 14 Nov 2016 02:50:34 +0000
Message-ID: <E1c67Lu-0001Lz-JH@gemulon.postgresql.org> (raw)
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

pg_upgrade: Upgrade sequence data via pg_dump

Previously, pg_upgrade migrated sequence data like tables by copying the
on-disk file.  This does not allow any changes in the on-disk format for
sequences.  It's simpler to just have pg_dump set the new sequence
values as it normally does.  To do that, create a hidden submode in
pg_dump that dumps sequence data even when a schema-only dump is
requested, and trigger that submode in binary upgrade mode.  (This new
submode could easily be exposed as a command-line option, but it has
limited use outside of pg_dump and would probably cause some confusion,
so we don't do that at this time.)

Reviewed-by: Anastasia Lubennikova <a.lubennikova@postgrespro.ru>
Reviewed-by: Michael Paquier <michael.paquier@gmail.com>

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/a7e5457db86642c078888bf666cf6b64636bb190

Modified Files
--------------
src/bin/pg_dump/pg_backup.h          |  3 +++
src/bin/pg_dump/pg_backup_archiver.c |  6 +++++-
src/bin/pg_dump/pg_dump.c            | 19 +++++++++++++++----
src/bin/pg_upgrade/info.c            |  2 +-
4 files changed, 24 insertions(+), 6 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


Message-ID: <E1c67Lu-0001Lz-JH@gemulon.postgresql.org>
Permalink:  ../E1c67Lu-0001Lz-JH@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1c67Lu-0001Lz-JH@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: peter_e@gmx.net
  Subject: Re: pgsql: pg_upgrade: Upgrade sequence data via pg_dump
  In-Reply-To: <E1c67Lu-0001Lz-JH@gemulon.postgresql.org>
  References: <E1c67Lu-0001Lz-JH@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox