Re: Logical replication support for generic wal record - Mailing list pgsql-hackers

From Natarajan R
Subject Re: Logical replication support for generic wal record
Date
Msg-id CAPqxBt58PYdMrRvMaoCOkRia=X+nvu+pvTqwNv-C+PvuJ5As7A@mail.gmail.com
Whole thread Raw
In response to Re: Logical replication support for generic wal record  (Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>)
Responses Re: Logical replication support for generic wal record
List pgsql-hackers

On Mon, 22 Aug 2022 at 12:16, Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com> wrote:
On Mon, Aug 22, 2022 at 11:59 AM Natarajan R <nataraj3098@gmail.com> wrote:
>
> Hi All,
>
> I am writing a postgres extension which writes only generic wal record, but this wal is not recognized by logical replication decoder. I have a basic understanding of how logical replication(COPY command for initial sync, wal replica for final sync) works, can you please tell us a way to support this?

"Generic" resource manager doesn't have a decoding API, see [1], which
means that the generic WAL records will not get decoded.

Can you be more specific about the use-case? Why use only "Generic"
type WAL records? Why not use "LogicalMessage" type WAL records if you
want your WAL records to be decoded?

I am writing an extension which implements postgres table access method interface[1] with master-slave architecture, with the help of doc[1] i decided to go with generic_wal to achieve crash_safety and also for streaming replication. It seems like generic_wal couldn't help with logical replication..
But, I don't have knowledge on "LogicalMessage" Resource Manager, need to explore about it.


pgsql-hackers by date:

Previous
From: Richard Guo
Date:
Subject: Re: Stack overflow issue
Next
From: David Rowley
Date:
Subject: Re: Fix typo in func.sgml