Re: Skipping logical replication transactions on subscriber side

Peter Eisentraut <peter.eisentraut@enterprisedb.com>

From: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
To: Amit Kapila <amit.kapila16@gmail.com>, Masahiko Sawada <sawada.mshk@gmail.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2021-05-31T19:25:55Z
Lists: pgsql-hackers
On 27.05.21 12:04, Amit Kapila wrote:
>>> Also, I am thinking that instead of a stat view, do we need
>>> to consider having a system table (pg_replication_conflicts or
>>> something like that) for this because what if stats information is
>>> lost (say either due to crash or due to udp packet loss), can we rely
>>> on stats view for this?
>> Yeah, it seems better to use a catalog.
>>
> Okay.

Could you store it shared memory?  You don't need it to be crash safe, 
since the subscription will just run into the same error again after 
restart.  You just don't want it to be lost, like with the statistics 
collector.



Commits

  1. Test ALIGNOF_DOUBLE==4 compatibility under ALIGNOF_DOUBLE==8.

  2. Reorder subskiplsn in pg_subscription to avoid alignment issues.

  3. Add ALTER SUBSCRIPTION ... SKIP.

  4. Optionally disable subscriptions on error.

  5. Update docs of logical replication for commit 8d74fc96db.

  6. Respect permissions within logical replication.

  7. Fix regression test failure caused by commit 8d74fc96db.

  8. Add a view to show the stats of subscription workers.

  9. Add logical change details to logical replication worker errcontext.

  10. Rename LOGICAL_REP_MSG_STREAM_END to LOGICAL_REP_MSG_STREAM_STOP.

  11. Fix typo in protocol.sgml.

  12. Remove unused argument in apply_handle_commit_internal().

  13. Fix replication of in-progress transactions in tablesync worker.

  14. Reorder pg_sequence columns to avoid alignment issue