Hi Michael,
Thanks for your reply!
The related source code located on src/backend/replication/logical/origin.c and it's marked as new file .
The error is from this function: replorigin_check_prerequisites
And you perform the WAL log offset reset function, must do a validation by replorigin_check_prerequisites.
So am not sure it's a bug or not on standby database, or some dev can fix it on next version?
(like add some logicals to identify the database role first...)
========================================================================================
On Mon, Jul 15, 2024 at 08:28:26AM +0000, PG Bug reporting form wrote:
> Seems the function pg_replication_origin_advance is not supported running on
> standby instance. It there any workaround for it?
Not that I know of. One would need to study how to lift this
restriction in place since the introduction of replication origins in
5aa2350426c4.
--
Michael
========================================================================================
Thanks
Jason
发件人: Michael Paquier <michael@paquier.xyz>
发送时间: 2024年7月16日 9:00
收件人: Jason ChenTJ (CN) <Jason.ChenTJ@homecredit.cn>; pgsql-bugs@lists.postgresql.org <pgsql-bugs@lists.postgresql.org>
主题: [External]Re: BUG #18540: Does PG16 standby database support function pg_replication_origin_advance?
This message is from an EXTERNAL SENDER - be CAUTIOUS, particularly with links and attachments.
________________________________