Subject: pgsql: Separate RecoveryConflictReasons from procsignals

From: Heikki Linnakangas <[email-masked]>
Date: Tue, 10 Feb 2026 14:32:37 +0000

Separate RecoveryConflictReasons from procsignals

Share the same PROCSIG_RECOVERY_CONFLICT flag for all recovery
conflict reasons. To distinguish, have a bitmask in PGPROC to indicate
the reason(s).

Reviewed-by: Chao Li <[email-masked]>
Discussion: https://www.postgresql.org/message-id/[email-masked]

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/17f51ea818753093f929b4c235f3b89ebcc7c5fb

Modified Files
--------------
src/backend/commands/dbcommands.c            |   1 +
src/backend/commands/tablespace.c            |   1 +
src/backend/replication/logical/logicalctl.c |   1 +
src/backend/replication/slot.c               |   6 +-
src/backend/storage/buffer/bufmgr.c          |   5 +-
src/backend/storage/ipc/procarray.c          | 136 ++++++++++++++++++---------
src/backend/storage/ipc/procsignal.c         |  22 +----
src/backend/storage/ipc/standby.c            |  61 ++++++------
src/backend/storage/lmgr/proc.c              |   5 +-
src/backend/tcop/postgres.c                  | 117 ++++++++++++-----------
src/backend/utils/activity/pgstat_database.c |  18 ++--
src/backend/utils/adt/mcxtfuncs.c            |   1 +
src/include/storage/proc.h                   |  10 ++
src/include/storage/procarray.h              |   7 +-
src/include/storage/procsignal.h             |  16 +---
src/include/storage/standby.h                |  34 ++++++-
src/include/tcop/tcopprot.h                  |   2 +-
src/tools/pgindent/typedefs.list             |   1 +
18 files changed, 258 insertions(+), 186 deletions(-)

---

From: Bertrand Drouvot <[email-masked]>
Date: Tue, 10 Feb 2026 15:19:09 +0000

Hi,

> conflict reasons. To distinguish, have a bitmask in PGPROC to indicate

I did not look at the thread, so sorry to be late, but that makes the size of PGPROC
going from 832 to 840 bytes, so not a multiple of 64 anymore. Is that something
to worry about? (same kind of discussion in [1]).

[1]: https://postgr.es/m/tw53roer2j4quxh7vlyv62drc5fo6c6zdltvl6d2dttqa62uhi%40stwlpdwlftpj

Regards,

-- 
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com