pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Simon Riggs <simon@2ndQuadrant.com>
To: pgsql-committers@postgresql.org
Subject: pgsql: Ability to advance replication slots
Date: Wed, 17 Jan 2018 11:42:23 +0000
Message-ID: <E1ebm6p-000761-Hc@gemulon.postgresql.org> (raw)

Ability to advance replication slots

Ability to advance both physical and logical replication slots using a
new user function pg_replication_slot_advance().

For logical advance that means records are consumed as fast as possible
and changes are not given to output plugin for sending. Makes 2nd phase
(after we reached SNAPBUILD_FULL_SNAPSHOT) of replication slot creation
faster, especially when there are big transactions as the reorder buffer
does not have to deal with data changes and does not have to spill to
disk.

Author: Petr Jelinek
Reviewed-by: Simon Riggs

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/9c7d06d60680c7f00d931233873dee81fdb311c6

Modified Files
--------------
contrib/test_decoding/expected/slot.out        |  30 ++++
contrib/test_decoding/sql/slot.sql             |  15 ++
doc/src/sgml/func.sgml                         |  19 +++
src/backend/replication/logical/decode.c       |  44 ++++--
src/backend/replication/logical/logical.c      |  30 +++-
src/backend/replication/logical/logicalfuncs.c |   1 +
src/backend/replication/slotfuncs.c            | 200 +++++++++++++++++++++++++
src/backend/replication/walsender.c            |   1 +
src/include/catalog/pg_proc.h                  |   2 +
src/include/replication/logical.h              |   8 +
10 files changed, 333 insertions(+), 17 deletions(-)



Message-ID: <E1ebm6p-000761-Hc@gemulon.postgresql.org>
Permalink:  ../E1ebm6p-000761-Hc@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1ebm6p-000761-Hc@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: simon@2ndQuadrant.com
  Subject: Re: pgsql: Ability to advance replication slots
  In-Reply-To: <E1ebm6p-000761-Hc@gemulon.postgresql.org>
  References: <E1ebm6p-000761-Hc@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