Re: Timeline following for logical slots

From: Petr Jelinek <petr(at)2ndquadrant(dot)com>
To: Craig Ringer <craig(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Álvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Andres Freund <andres(at)anarazel(dot)de>
Subject: Re: Timeline following for logical slots
Date: 2016-03-09 23:25:21
Message-ID: 56E0B0E1.603@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 04/03/16 17:08, Craig Ringer wrote:
> I'd really appreciate some review of the logic there by people who know
> timelines well and preferably know the xlogreader. It's really just one
> function and 2/3 comments; the code is simple but the reasoning leading
> to it is not.
>

I think this will have to be work for committer at this point. I can't
find any flaws in the logic myself so I unless somebody protests I am
going to mark this as ready for committer.

> I've also attached an updated version of the tests posted a few days
> ago. The tests depend on the remaining patches from the TAP
> enhancements tree so it's easiest to just get the whole tree from
> https://github.com/2ndQuadrant/postgres/tree/dev/logical-decoding-timeline-following
> (subject to regular rebases and force pushes, do not use as a base).
>
> The tests now include a test module that exposes some slots guts to SQL
> to allow the client to sync slot state from master to replica(s) without
> needing failover slots and the use of extra WAL as transport. It's very
> much for-testing-only.
>
> The new test module is used by a second round of tests to demonstrate
> the practicality of failover of a logical replication client to a
> physical replica using a base backup taken by pg_basebackup and without
> the presence of failover slots. I won't pretend it's pretty.
>

Well for testing purposes it's quite fine I think. The TAP framework
enhancements needed for this are now in and it works correctly against
current master.

--
Petr Jelinek http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2016-03-09 23:35:53 Re: Proposal: "Causal reads" mode for load balancing reads without stale data
Previous Message David Steele 2016-03-09 23:11:12 Re: Patch: Implement failover on libpq connect level.