Re: Add the replication origin name and commit-LSN to logical replication worker errcontext
От | Euler Taveira |
---|---|
Тема | Re: Add the replication origin name and commit-LSN to logical replication worker errcontext |
Дата | |
Msg-id | 45c0cd68-ec87-4b2a-940e-b6ce529060c7@www.fastmail.com обсуждение исходный текст |
Ответ на | Re: Add the replication origin name and commit-LSN to logical replication worker errcontext (Amit Kapila <amit.kapila16@gmail.com>) |
Ответы |
Re: Add the replication origin name and commit-LSN to logical replication worker errcontext
Re: Add the replication origin name and commit-LSN to logical replication worker errcontext |
Список | pgsql-hackers |
On Fri, Mar 4, 2022, at 2:54 AM, Amit Kapila wrote:
The LSN of the transaction that contains the change violating theconstraint and the replication origin name can be found from theserver log (LSN 0/14C0378 and replication origin<literal>pg_16395</literal> in the above case). To skip thetransaction, the subscription needs to be disabled temporarily by<command>ALTER SUBSCRIPTION ... DISABLE</command> first. Then, thetransaction can be skipped by calling the <linklinkend="pg-replication-origin-advance"><function>pg_replication_origin_advance()</function></link> functionwith the <parameter>node_name</parameter> (i.e.,<literal>pg_16395</literal>) and the next LSN of the commit LSN (i.e.,LSN 0/14C0379).
You could also add:
After that the replication can be resumed by <command>ALTER SUBSCRIPTION ...
ENABLE</command>.
Let's provide complete instructions.
В списке pgsql-hackers по дате отправления: