Re: UPDATE operation terminates logical replication receiver process due to an assertion
Justin Pryzby <pryzby@telsasoft.com>
From: Justin Pryzby <pryzby@telsasoft.com>
To: v.davydov@postgrespro.ru
Cc: pgsql-hackers@lists.postgresql.org, tgl@sss.pgh.pa.us
Date: 2023-01-15T16:24:49Z
Lists: pgsql-hackers
On Thu, Jan 12, 2023 at 01:23:57PM +0300, v.davydov@postgrespro.ru wrote:
> Dear all,
>
> I think I've found a problem in logical replication that was introduced
> recently in the patch:
>
> Fix calculation of which GENERATED columns need to be updated
> https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=3f7836ff651ad710fef52fa87b248ecdfc6468dc
> There is an assertion which accidentally terminates logical replication
> worker process. The assertion was introduced in the patch. To reproduce the
> problem Postgres should be compiled with enabled assertions. The problem
> appears when executing UPDATE operation on a non-empty table with GENERATED
> columns and a BEFORE UPDATE trigger. The problem seems to appear on the
> latest snapshots of 13 and 14 versions (sorry, I haven't tested other
> versions).
>
> Stack:
> ------
> TRAP: FailedAssertion("relinfo->ri_GeneratedExprs != NULL", File: "execUtils.c", Line: 1292)
Yeah, confirmed under master branch and v15.
Tom ?
--
Justin
Commits
-
Make new GENERATED-expressions code more bulletproof.
- a8f7687a0b86 15.2 landed
- a8b88c26f706 14.7 landed
- 787db4be947c 13.10 landed
- 3f244d020fbf 16.0 landed
-
Fix calculation of which GENERATED columns need to be updated.
- 8cd190e13a22 14.7 cited
- 3f7836ff651a 16.0 cited