public inbox for [email protected]
help / color / mirror / Atom feedFrom: Andres Freund <[email protected]>
To: [email protected]
Subject: pgsql: pgstat: Allow checksum errors to be reported in critical section
Date: Sun, 30 Mar 2025 20:28:43 +0000
Message-ID: <[email protected]> (raw)
pgstat: Allow checksum errors to be reported in critical sections
For AIO we execute completion callbacks in critical sections (to ensure that
AIO can in the future be used for WAL, which in turn requires that we can call
completion callbacks in critical sections, to get the resources for WAL
io). To report checksum errors a backend now has to call
pgstat_prepare_report_checksum_failure(), before entering a critical section,
which guarantees the relevant pgstats entry is in shared memory, the relevant
DSM segment is mapped into the backend's memory and the address is known via a
PgStat_EntryRef.
Reviewed-by: Noah Misch <[email protected]>
Discussion: https://postgr.es/m/wkjj4p2rmkevutkwc6tewoovdqznj6c6nvjmvii4oo5wmbh5sr@retq7d6uqs4j
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/b96d3c389755fc5d20f4a5b9ded58b68541b8ba3
Modified Files
--------------
src/backend/backup/basebackup.c | 1 +
src/backend/catalog/storage.c | 1 +
src/backend/storage/buffer/bufmgr.c | 1 +
src/backend/utils/activity/pgstat_database.c | 51 ++++++++++++++++++++++++++--
src/include/pgstat.h | 1 +
5 files changed, 52 insertions(+), 3 deletions(-)
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: [email protected]
Cc: [email protected], [email protected]
Subject: Re: pgsql: pgstat: Allow checksum errors to be reported in critical section
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox