pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Heikki Linnakangas <heikki.linnakangas@iki.fi>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Add callback for I/O error messages in SLRUs
Date: Fri, 13 Mar 2026 14:31:59 +0000
Message-ID: <E1w13YV-003qKC-0e@gemulon.postgresql.org> (raw)

Add callback for I/O error messages in SLRUs

Historically, all SLRUs were addressed by transaction IDs, but that
hasn't been true for a long time. However, the error message on I/O
error still always talked about accessing a transaction ID.

This commit adds a callback that allows subsystems to construct their
own error messages, which can then correctly refer to a transaction
ID, multixid or whatever else is used to address the particular SLRU.

Author: Maxim Orlov <orlovmg@gmail.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Discussion: https://www.postgresql.org/message-id/CACG=ezZZfurhYV+66ceubxQAyWqv9vaUi0yoO4-t48OE5xc0DQ@mail.gmail...

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/f9de9bf302d2df41da06c6377ba1904883cd9d51

Modified Files
--------------
src/backend/access/transam/clog.c                 | 17 +++--
src/backend/access/transam/commit_ts.c            | 13 +++-
src/backend/access/transam/multixact.c            | 65 ++++++++++++++-----
src/backend/access/transam/slru.c                 | 79 ++++++++++++-----------
src/backend/access/transam/subtrans.c             | 14 +++-
src/backend/commands/async.c                      | 20 ++++--
src/backend/storage/lmgr/predicate.c              | 14 +++-
src/include/access/slru.h                         | 15 ++++-
src/test/modules/test_slru/expected/test_slru.out |  4 ++
src/test/modules/test_slru/sql/test_slru.sql      |  3 +
src/test/modules/test_slru/test_slru--1.0.sql     |  2 +-
src/test/modules/test_slru/test_slru.c            | 15 ++++-
src/tools/pgindent/typedefs.list                  |  1 +
13 files changed, 187 insertions(+), 75 deletions(-)



Message-ID: <E1w13YV-003qKC-0e@gemulon.postgresql.org>
Permalink:  ../E1w13YV-003qKC-0e@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1w13YV-003qKC-0e@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: heikki.linnakangas@iki.fi, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Add callback for I/O error messages in SLRUs
  In-Reply-To: <E1w13YV-003qKC-0e@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox