Logical WAL streaming & START_REPLICATION - Mailing list pgsql-jdbc

From Joe Hammerman
Subject Logical WAL streaming & START_REPLICATION
Date
Msg-id CAFZjsjCMLk4yQa8nhZ8Mj6fdSRs3gDws6G1YGdnD6LRGmi+DHg@mail.gmail.com
Whole thread Raw
Responses Re: Logical WAL streaming & START_REPLICATION  (Craig Ringer <craig@2ndquadrant.com>)
List pgsql-jdbc
Hi pgsql-jdbc users email distribution list,

We are using the JDBC Driver bundled with the Debezium project. We are trying to reset the replication stream from a WAL log point in the past. This effort is in service of developing a disaster recovery plan, with the idea that a flushed LSN may have been in the Kafka Broker Pool but not consumed. The missing WAL files may still exist on disk, so it would be ideal if we could begin streaming from a given WAL log file.

To that end, we have configured the Kafka Connect daemon to begin streaming from a paritcular WAL log file.

Consider the following logs which show the creation of a new logical replication slot:


Although START_REPLICATION is called with the x_log position we desire, streaming is picked up from the current WAL log position.

Is there a method to achieve our ends? Our alternative plan is to add a republish_count field to the the transaction, so that we can craft an SQL statement to update the rows from say, an hour ago to the present time.


pgsql-jdbc by date:

Previous
From: Vladimir Sitnikov
Date:
Subject: [pgjdbc/pgjdbc] af64ed: fix: allowEncodingChanges should allow setclient_...
Next
From: Craig Ringer
Date:
Subject: Re: Logical WAL streaming & START_REPLICATION