Limited beta · What is this?

pgTrue is under active development: reports may contain significant mistakes, inaccuracies, or bugs. Please report anything you find to pgtrue@postgres.ai.

pgTrue is an independent fact-check of technical Postgres articles. Read the questions and answers.

pgTrue fact-check

ElephantSeal BLimited coverageOpen: the benchmark cannot yet be rerun from what is published

Embed

The ElephantSeal always shows this report's latest edition and links here. Copies cached elsewhere may update later.

[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&theme=light)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&amp;theme=light" alt="pgTrue fact-check" width="90" height="20" loading="lazy" decoding="async" style="display:inline-block;width:90px;height:20px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&theme=light
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&theme=light
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 90
   :height: 20
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&theme=dark)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&amp;theme=dark" alt="pgTrue fact-check" width="90" height="20" loading="lazy" decoding="async" style="display:inline-block;width:90px;height:20px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&theme=dark
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13&theme=dark
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 90
   :height: 20
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13" alt="pgTrue fact-check" width="90" height="20" loading="lazy" decoding="async" style="display:inline-block;width:90px;height:20px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c.svg?v=13
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 90
   :height: 20
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&theme=light)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&amp;theme=light" alt="pgTrue fact-check" width="240" height="240" loading="lazy" decoding="async" style="display:inline-block;width:240px;height:240px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&theme=light
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&theme=light
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 240
   :height: 240
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&theme=dark)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&amp;theme=dark" alt="pgTrue fact-check" width="240" height="240" loading="lazy" decoding="async" style="display:inline-block;width:240px;height:240px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&theme=dark
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13&theme=dark
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 240
   :height: 240
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13" alt="pgTrue fact-check" width="240" height="240" loading="lazy" decoding="async" style="display:inline-block;width:240px;height:240px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/radar.svg?v=13
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 240
   :height: 240
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&theme=light)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&amp;theme=light" alt="pgTrue fact-check" width="480" height="240" loading="lazy" decoding="async" style="display:inline-block;width:480px;height:240px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&theme=light
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&theme=light
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 480
   :height: 240
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&theme=dark)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&amp;theme=dark" alt="pgTrue fact-check" width="480" height="240" loading="lazy" decoding="async" style="display:inline-block;width:480px;height:240px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&theme=dark
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13&theme=dark
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 480
   :height: 240
[![pgTrue fact-check](https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13)](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c)
<a href="https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c"><img src="https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13" alt="pgTrue fact-check" width="480" height="240" loading="lazy" decoding="async" style="display:inline-block;width:480px;height:240px"></a>
https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13
.. image:: https://pgtrue.postgres.ai/badge/d44845a1-484a-4f98-9401-6eb9d4594e1c/wide.svg?v=13
   :target: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
   :alt: pgTrue fact-check
   :width: 480
   :height: 240

Click the snippet to select all of it, then copy. Where SVG is stripped, as in some email clients and feed readers, change .svg to .png. PNG uses the light theme for Auto. For Markdown PNG embeds, use the HTML snippet where supported to preserve the display size.

Optional colours: append &color=26798E or &labelColor=333C47 after a theme query (use ? for the first parameter). Use 3- or 6-digit hex.

For pages with a light background.

For pages with a dark background. The ElephantSeal gets a thin edge so it does not blend in.

Auto follows the reader's light or dark setting where the host supports it, and shows the light ElephantSeal where it does not.

On a light page
On a dark page

PostgreSQL subtransactions considered harmful (opens in new tab)

postgres.ai
Check before you follow it: 1 claim is wrong.
0
inaccuracy
0
dangerous-recipe
1
misleading
0
imprecise
0
transcription
0
aged
0
withdrawn
20
verified-accurate

Factual B+ · Applicable A · Consistent A · Transparent D · Safe A

ReportTechnical fact-check, edition 3 Issued EditionUpdated after review. Corrections are listed below. SubmittedSubmitted by the PostgresAI team. Author responseNo written reply from the author. The article changed 1 time after our first audit; we re-audited each version. See Revisions below. Policy: right-of-reply and corrections policy. pgTrue versionaudited with v1.0.14 (approx.) · regraded with v1.1.1 (approx.)

InaccuraciesNone in this edition.

Dangerous or recipe bugsNone in this edition.

Misleading / imprecise

F1

RELEASE SAVEPOINT does not prevent the 64-XID cache overflow

MISLEADINGFactual · holds up after review

Claim ledger

Article says
…no degradation happens when passing the threshold defined by PGPROC_MAX_CACHED_SUBXIDS…
What is true
Released children remain non-aborted children until the top-level transaction ends. xact.c:4814-4816 retains their XIDs, and varsup.c:227-234 sets overflow on the next uncached child. A nesting depth of 1 can exceed 64 child XIDs. Relying on RELEASE can waste mitigation work.
So what
Limit assigned, non-aborted child XIDs per top-level transaction. Split large transactions instead of relying on RELEASE SAVEPOINT.
Charitable reading
The reported benchmark can show no measurable slowdown. That observation does not establish that RELEASE SAVEPOINT prevents overflow.

Source

Source · REL_12_8 · src/include/storage/proc.h:25-36* Each backend advertises up to PGPROC_MAX_CACHED_SUBXIDS TransactionIds * for non-aborted subtransactions of its current top transaction. These * have to be treated as running XIDs by other backends.
In the article · section “Problem 2: per-session cache overflow”

In the article

excerpt · section “Problem 2: per-session cache overflow” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 2: per-session cache overflow

What happens if we run RELEASE SAVEPOINT statements to maintain the number of active subtransactions below PGPROC_MAX_CACHED_SUBXIDS ? Result: no degradation happens when passing the threshold defined by PGPROC_MAX_CACHED_SUBXIDS , even if we created overall 100 subtransactions in each transaction.

All sources and excerpts · 5
Evidence * Each backend advertises up to PGPROC_MAX_CACHED_SUBXIDS TransactionIds * for non-aborted subtransactions of its current top transaction. These * have to be treated as running XIDs by other backends.
Evidence if (nxids < PGPROC_MAX_CACHED_SUBXIDS) { MyProc->subxids.xids[nxids] = xid; pg_write_barrier(); MyPgXact->nxids = nxids + 1; } else MyPgXact->overflowed = true;
Evidence * Pass my own XID and my child XIDs up to my parent as committed children.
Evidence#define PGPROC_MAX_CACHED_SUBXIDS 64 /* XXX guessed-at value */
Evidence /* Post-commit cleanup */ if (FullTransactionIdIsValid(s->fullTransactionId)) AtSubCommit_childXids(); AfterTriggerEndSubXact(true);
How the review tested this

Review: The benchmark could show no degradation. That does not establish that RELEASE prevents overflow. Retained child XIDs support the mitigation warning. We tested the charitable reading that RELEASE produced no measurable slowdown. F1 preserves that possibility. The source supports retained child XIDs and overflow after 64 cached children. Splitting transactions names a concrete mitigation. Wasted work matches the evidence.

Verified accurate

F2

XID assignment also assigns unidentified ancestors

ACCURATEFactual · holds up after review

Claim ledger

Article says
…all of them get their own XID assigned…
What is true
AssignTransactionId assigns XIDs to ancestors before assigning the child. PostgreSQL 12.8 documents this invariant in xact.c:548-552.
Charitable reading
The sentence applies to ancestors of an innermost subtransaction that receives an XID.

Source

Source · REL_12_8 · src/backend/access/transam/xact.c:548-552* Also, any parent TransactionStates that don't yet have XIDs are assigned * one; this maintains the invariant that a child transaction has an XID * following its parent's.
In the article · section “Problem 1: XID growth”

In the article

excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 1: XID growth

One of the basic issues with subtransactions is that they increment XID – the global transaction ID. As with regular transactions, this happens only if there is some modifying work – but if there are multiple nested subtransactions, all of them get their own XID assigned, even if a single modification happened inside the inneter-most of them.

test=# create table test1(i int8); CREATE TABLE test=# begin; BEGIN test=*# select pg_current_xact_id(); -- use txid_current() in Postgres 12 or older pg_current_xact_id -------------------- 1549100656 (1 row) test=*# insert into test1 select 1; INSERT 0 1 test=*# savepoint s1; SAVEPOINT test=*# insert into test1 select 2; INSERT 0 1 test=*# savepoint s2; SAVEPOINT test=*# savepoint s3; SAVEPOINT test=*# insert into test1 select 3; INSERT 0 1 test=*# commit; COMMIT test=# select pg_current_xact_id(); pg_current_xact_id -------------------- 1549100660 (1 row) test=# select ctid, xmin, xmax, i from test1; ctid  |    xmin    | xmax | i -------+------------+------+--- (0,1) | 1549100656 |    0 | 1 (0,2) | 1549100657 |    0 | 2 (0,3) | 1549100659 |    0 | 3 (3 rows)
All sources and excerpts · 1
Evidence * Also, any parent TransactionStates that don't yet have XIDs are assigned * one; this maintains the invariant that a child transaction has an XID * following its parent's.
How the review tested this

Review: We checked the innermost-write hypothesis. AssignTransactionId explicitly assigns previously unidentified ancestors. We checked whether F2 extended assignment to unrelated children. It restricts the claim to ancestors. xact.c confirms that invariant.

F3

PL/pgSQL exception blocks create subtransactions

ACCURATEFactual · holds up after review

Claim ledger

Article says
…BEGIN / EXCEPTION WHEN .. / END blocks in PL/pgSQL code…
What is true
pl_exec.c:1683-1707 executes an exception block inside an internal subtransaction. PostgreSQL 12.8 documents the same behavior in plpgsql.sgml:310-313.
Charitable reading
The article names blocks containing EXCEPTION, rather than ordinary BEGIN/END blocks.

Source

Source · REL_12_8 · doc/src/sgml/plpgsql.sgml:305-314Also, a block containing an <literal>EXCEPTION</literal> clause effectively forms a subtransaction that can be rolled back without affecting the outer transaction. For more about that see <xref linkend="plpgsql-error-trapping"/>.
In the article · section “Who is using subtransactions?”

In the article

excerpt · section “Who is using subtransactions?” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Who is using subtransactions?

BEGIN / EXCEPTION WHEN .. / END blocks in PL/pgSQL code (the official documentation does not describe it well; explored, for example, in this article: "PL/PgSQL Exception and XIDs" )

All sources and excerpts · 2
Evidence Also, a block containing an <literal>EXCEPTION</literal> clause effectively forms a subtransaction that can be rolled back without affecting the outer transaction. For more about that see <xref linkend="plpgsql-error-trapping"/>.
Evidence if (block->exceptions) { /* * Execute the statements in the block's body inside a sub-transaction */
How the review tested this

Review: We tested whether ordinary blocks were conflated with exception blocks. Both the quotation and implementation require an EXCEPTION clause. We checked the distinction between ordinary blocks and exception blocks. pl_exec.c starts an internal subtransaction only in the exception branch.

F4

PL/Python supports explicit subtransaction contexts

ACCURATEFactual · holds up after review

Claim ledger

Article says
…plpy.subtransaction() in PL/Python code…
What is true
plpython.sgml:1294-1298 documents plpy.subtransaction(). Its context-entry implementation calls BeginInternalSubTransaction in plpy_subxactobject.c:117.
Charitable reading
The function supplies a context manager. Entering that context starts the subtransaction.

Source

Source · REL_12_8 · src/pl/plpython/plpy_subxactobject.c:108-120BeginInternalSubTransaction(NULL);
In the article · section “Who is using subtransactions?”

In the article

excerpt · section “Who is using subtransactions?” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Who is using subtransactions?

plpy.subtransaction() in PL/Python code

All sources and excerpts · 2
Evidence BeginInternalSubTransaction(NULL);
Evidence subtransaction. The <literal>plpy</literal> module provides a helper object to manage explicit subtransactions that gets created with the <literal>plpy.subtransaction()</literal> function.
How the review tested this

Review: Creating the helper and entering its context differ. The finding correctly attributes transaction creation to context entry. We tested whether calling the constructor alone starts a subtransaction. F4 correctly identifies context entry as the operative step.

F5

The revised standby lookup conditions match PostgreSQL 12.8

ACCURATEFactual · holds up after review

Claim ledger

Article says
…look up their top-level parent in pg_subtrans…
What is true
snapmgr.c:2253-2258 returns before parent lookup for XIDs outside [xmin, xmax). The recovery branch calls SubTransGetTopmostTransaction when suboverflowed is set. That branch accepts both top-level and child XIDs.
Charitable reading
The article explicitly conditions lookup on recovery snapshots, suboverflowed, and the xmin-to-xmax range.

Source

Source · REL_12_8 · src/backend/utils/time/snapmgr.c:2253-2258/* Any xid < xmin is not in-progress */ if (TransactionIdPrecedes(xid, snapshot->xmin)) return false; /* Any xid >= xmax is in-progress */ if (TransactionIdFollowsOrEquals(xid, snapshot->xmax)) return true;
In the article · section “Problem 4: Subtrans SLRU overflow”

In the article

excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 4: Subtrans SLRU overflow

What's happening here? The workload on the primary issues UPDATEs in transactions involving subtransactions. When a standby snapshot has suboverflowed set, visibility checks for XIDs in the snapshot's xmin -to- xmax range ( xmin inclusive, xmax exclusive) look up their top-level parent in pg_subtrans . This applies to top-level XIDs as well as subtransaction XIDs, not to every tuple read. XIDs outside that range return before the parent lookup. A long-running transaction can keep the snapshot's xmin low, widening the range of XIDs that need these lookups – there is a global cache for all subtransactions, also SLRU ("simple least-recently-used" cache, see slru.c ), but very small – see subtrans.h :

/* Number of SLRU buffers to use for subtrans */ # define NUM_SUBTRANS_BUFFERS 32
All sources and excerpts · 2
Evidence /* Any xid < xmin is not in-progress */ if (TransactionIdPrecedes(xid, snapshot->xmin)) return false; /* Any xid >= xmax is in-progress */ if (TransactionIdFollowsOrEquals(xid, snapshot->xmax)) return true;
Evidence if (snapshot->suboverflowed) { /* * Snapshot overflowed, so convert xid to top-level. This is safe * because we eliminated too-old XIDs above. */ xid = SubTransGetTopmostTransaction(xid);
How the review tested this

Review: We checked both range boundaries and the recovery branch. The revised explanation includes their conditions and covers top-level XIDs. We checked both range boundaries and the recovery branch. The revised article includes those conditions. F5 does not endorse the removed universal explanation.

F6

The default Subtrans cache contains 32 pages

ACCURATEFactual · holds up after review

Claim ledger

Article says
…NUM_SUBTRANS_BUFFERS 32…
What is true
PostgreSQL 12.8 defines 32 Subtrans buffers and 4-byte TransactionIds. Default BLCKSZ is 8 KiB. The cache covers 65,536 XID positions (derived: 32 × 8,192 / 4). subtrans.c:52-55 maps global XID positions to pages and entries.
Charitable reading
The 65,536-entry calculation assumes the default 8 KiB build.

Source

Source · REL_12_8 · src/include/access/subtrans.h:13-16#define NUM_SUBTRANS_BUFFERS 32
In the article · section “Problem 4: Subtrans SLRU overflow”

In the article

excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 4: Subtrans SLRU overflow

/* Number of SLRU buffers to use for subtrans */ # define NUM_SUBTRANS_BUFFERS 32
/* We need four bytes per xact */ # define SUBTRANS_XACTS_PER_PAGE ( BLCKSZ / sizeof ( TransactionId ) ) # define TransactionIdToPage ( xid ) ( ( xid ) / ( TransactionId ) SUBTRANS_XACTS_PER_PAGE ) # define TransactionIdToEntry ( xid ) ( ( xid ) % ( TransactionId ) SUBTRANS_XACTS_PER_PAGE )
All sources and excerpts · 6
Evidence#define NUM_SUBTRANS_BUFFERS 32
Evidence/* We need four bytes per xact */ #define SUBTRANS_XACTS_PER_PAGE (BLCKSZ / sizeof(TransactionId)) #define TransactionIdToPage(xid) ((xid) / (TransactionId) SUBTRANS_XACTS_PER_PAGE) #define TransactionIdToEntry(xid) ((xid) % (TransactionId) SUBTRANS_XACTS_PER_PAGE)
EvidencePGAC_ARG_REQ(with, blocksize, [BLOCKSIZE], [set table block size in kB [8]], [blocksize=$withval], [blocksize=8])
Evidencetypedef uint32 TransactionId;
Evidence if (TransactionIdToEntry(newestXact) != 0 && !TransactionIdEquals(newestXact, FirstNormalTransactionId)) return;

Version note: The pin names the control lock SubtransControlLock.

Evidence * We use a simple least-recently-used scheme to manage a pool of page * buffers. Under ordinary circumstances we expect that write
How the review tested this

Review: We checked configurable block size and sparse occupancy. The finding specifies the default build and counts positions, not occupied children. We tested custom block sizes and sparse entries. F6 specifies the default build and counts XID positions. The constants yield 65,536 positions.

F7

MultiXact expansion creates a replacement identifier

ACCURATEFactual · holds up after review

Claim ledger

Article says
…entries are immutable…
What is true
multixact.c:424-426 states that expansion creates another MultiXact instead of changing existing membership. The implementation copies still-relevant members before adding the new member.
Charitable reading
The surrounding example concerns concurrent lockers whose memberships remain relevant.

Source

Source · REL_12_8 · src/backend/access/transam/multixact.c:418-426* Note that we do NOT actually modify the membership of a pre-existing * MultiXactId; instead we create a new one. This is necessary to avoid
In the article · section “Problem 3: unexpected use of Multixact IDs”

In the article

excerpt · section “Problem 3: unexpected use of Multixact IDs” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 3: unexpected use of Multixact IDs

One fun fact about the MultiXact store is that entries are immutable; if a new transaction locks a row that is already locked, a new MultiXact ID must be created, containing all the old transaction IDs as well as the new ID. This means that having N processes locking a row concurrently requires potentially quadratic work, since the list of transaction IDs must be copied in full, each time! This behavior is usually fine, since it's rare to have many transactions locking the same row at once, but already suggests that SELECT FOR SHARE has some potentially-disastrous performance cliffs.

All sources and excerpts · 1
Evidence * Note that we do NOT actually modify the membership of a pre-existing * MultiXactId; instead we create a new one. This is necessary to avoid
How the review tested this

Review: An already-present member can return the existing identifier. That exception does not contradict immutability when membership actually expands. We checked whether an existing member always forces expansion. The source permits returning the existing identifier. F7 concerns adding new membership and preserves that distinction.

F8

pg_stat_activity exposes current wait events for sampling

ACCURATEFactual · holds up after review

Claim ledger

Article says
…using periodical sampling of pg_stat_activity…
What is true
PostgreSQL 12.8 exposes wait_event_type and wait_event through pg_stat_activity. monitoring.sgml:769 identifies wait_event as the current wait, or NULL. External sampling must retain historical observations.
Charitable reading
Periodic sampling collects observations over time. The view itself does not retain history.

Source

Source · REL_12_8 · src/backend/catalog/system_views.sql:732-756S.wait_event_type, S.wait_event,
In the article · section “Recommendation 1: good monitoring”

In the article

excerpt · section “Recommendation 1: good monitoring” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Recommendation 1: good monitoring

wait event analysis (can be implemented using pgsentinel , pg_wait_sampling , or, at least, if you cannot install those, using periodical sampling of pg_stat_activity ; ad hoc tools like pgCenter or PASH Viewer can be helpful too, but it's important to have something that can collect historical data – incidents may happen suddenly and go away suddenly too, so having historical data is essential for a post mortem analysis)

All sources and excerpts · 2
Evidence S.wait_event_type, S.wait_event,
Evidence <entry>Wait event name if backend is currently waiting, otherwise NULL.
How the review tested this

Review: We checked whether current wait fields establish historical monitoring. The finding correctly requires external retention. We tested whether pg_stat_activity retains historical waits. F8 explicitly requires external retention. The view exposes the current wait fields.

F9

The sleep-and-watch recipe creates the described transaction cadence

ACCURATEFactual · holds up after review

Claim ledger

Article says
…pg_sleep_for ( '5 minutes' )…
What is true
pg_sleep_for accepts an interval and sleeps for that interval. txid_current assigns a top-level XID when needed. psql's documented watch interval waits between executions. The article's 300-second interval adds a five-minute break after each five-minute query.
Charitable reading
The SQL holds its implicit transaction while sleeping. The watch interval applies between executions.

Source

Source · REL_12_8 · src/include/catalog/pg_proc.dat:6085-6088{ oid => '3935', descr => 'sleep for the specified interval', proname => 'pg_sleep_for', prolang => 'sql', provolatile => 'v', prorettype => 'void', proargtypes => 'interval',
In the article · section “Problem 4: Subtrans SLRU overflow”

In the article

excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 4: Subtrans SLRU overflow

select txid_current ( ) , pg_sleep_for ( '5 minutes' ) \watch 300
echo "\\set id random(1, 10000) select * from pgbench_accounts where aid = :id;" > selects.sql pgbench  -rn -P2 -T36000 -c15 -j15 \ -f selects.sql \ -M prepared \ test -U postgres \ 2>&1 | ts | tee -a selects.log
All sources and excerpts · 3
Evidence{ oid => '3935', descr => 'sleep for the specified interval', proname => 'pg_sleep_for', prolang => 'sql', provolatile => 'v', prorettype => 'void', proargtypes => 'interval',
Evidence until interrupted or the query fails. Wait the specified number of seconds (default 2) between executions. Each query result is
Evidence <entry><literal><function>txid_current()</function></literal></entry> <entry><type>bigint</type></entry> <entry>get current transaction ID, assigning a new one if the current transaction does not have one</entry>
How the review tested this

Review: We checked interval units and whether watch waits between executions. PostgreSQL 12.8 documentation supports the stated cadence. We checked whether the 300-second interval includes query execution. PostgreSQL 12 documentation specifies waiting between executions. txid_current assigns an XID when needed.

F10

statement_timeout can cancel statements slowed by contention

ACCURATEFactual · holds up after review

Claim ledger

Article says
…statement_timeout…
What is true
PostgreSQL 12.8 aborts statements exceeding a positive statement_timeout. postgres.c:4716-4721 arms the timer only when the setting exceeds 0. The default 0 disables this timeout.
Charitable reading
The article describes configured production timeouts, rather than claiming that statement_timeout is enabled by default.

Source

Source · REL_12_8 · doc/src/sgml/config.sgml:7888-7918Abort any statement that takes more than the specified amount of time.
In the article · section “Problem 4: Subtrans SLRU overflow”

In the article

excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 4: Subtrans SLRU overflow

performance on the standby gradually drops to critical levels – the response time grows drastically, so user requests would hit timeouts (such as statement_timeout ) if it was a real-life production environment

All sources and excerpts · 2
Evidence Abort any statement that takes more than the specified amount of time.
Evidence if (StatementTimeout > 0) { if (!stmt_timeout_active) { enable_timeout_after(STATEMENT_TIMEOUT, StatementTimeout); stmt_timeout_active = true; } }
How the review tested this

Review: We checked whether the timeout was presented as enabled by default. The finding explicitly states that zero disables it. We tested the disabled default as a counterexample. F10 specifies a positive setting. The timer and documentation support cancellation.

F11

The transaction-ID example provides the PostgreSQL 12 fallback

ACCURATEFactual · holds up after review

Claim ledger

Article says
…use txid_current() in Postgres 12 or older…
What is true
PostgreSQL 12.8 documents txid_current(), including its XID-allocation behavior. PostgreSQL 13.0 defines pg_current_xact_id in pg_proc.dat:9579-9582. The article distinguishes these versions.
Charitable reading
The article supplies an explicit PostgreSQL 12 fallback for its newer function name.

Source

Source · REL_13_0 · src/include/catalog/pg_proc.dat:9579-9582proname => 'pg_current_xact_id', provolatile => 's', proparallel => 'u', prorettype => 'xid8', proargtypes => '', prosrc => 'pg_current_xact_id' },
In the article · section “Problem 1: XID growth”

In the article

excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 1: XID growth

test=# create table test1(i int8); CREATE TABLE test=# begin; BEGIN test=*# select pg_current_xact_id(); -- use txid_current() in Postgres 12 or older pg_current_xact_id -------------------- 1549100656 (1 row) test=*# insert into test1 select 1; INSERT 0 1 test=*# savepoint s1; SAVEPOINT test=*# insert into test1 select 2; INSERT 0 1 test=*# savepoint s2; SAVEPOINT test=*# savepoint s3; SAVEPOINT test=*# insert into test1 select 3; INSERT 0 1 test=*# commit; COMMIT test=# select pg_current_xact_id(); pg_current_xact_id -------------------- 1549100660 (1 row) test=# select ctid, xmin, xmax, i from test1; ctid  |    xmin    | xmax | i -------+------------+------+--- (0,1) | 1549100656 |    0 | 1 (0,2) | 1549100657 |    0 | 2 (0,3) | 1549100659 |    0 | 3 (3 rows)
All sources and excerpts · 2
Evidence proname => 'pg_current_xact_id', provolatile => 's', proparallel => 'u', prorettype => 'xid8', proargtypes => '', prosrc => 'pg_current_xact_id' },

Version note: Checked PostgreSQL 13.0 for the newer function name.

Evidence <entry><literal><function>txid_current()</function></literal></entry> <entry><type>bigint</type></entry> <entry>get current transaction ID, assigning a new one if the current transaction does not have one</entry>
How the review tested this

Review: We checked both release pins. PostgreSQL 13.0 contains the newer name, and PostgreSQL 12.8 documents the explicit fallback. We checked both release identifiers. The PostgreSQL 13 citation defines the newer name. PostgreSQL 12 documents the stated fallback.

F12

PostgreSQL 13 provides pg_stat_slru block counters

ACCURATEFactual · holds up after review

Claim ledger

Article says
…if PostgreSQL version is 13 or newer…
What is true
PostgreSQL 13.0 defines pg_stat_slru in system_views.sql:793 onward. The view includes each SLRU's name, block hits, block reads, and block writes.
Charitable reading
The monitoring recommendation explicitly requires PostgreSQL 13 or newer.

Source

Source · REL_13_0 · src/backend/catalog/system_views.sql:793-799CREATE VIEW pg_stat_slru AS SELECT s.name, s.blks_zeroed, s.blks_hit, s.blks_read, s.blks_written,
In the article · section “Recommendation 1: good monitoring”

In the article

excerpt · section “Recommendation 1: good monitoring” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Recommendation 1: good monitoring

A nice-to-have item here is a chart (or a few) with metrics from pg_stat_slru , if PostgreSQL version is 13 or newer.

All sources and excerpts · 1
EvidenceCREATE VIEW pg_stat_slru AS SELECT s.name, s.blks_zeroed, s.blks_hit, s.blks_read, s.blks_written,

Version note: Checked the article's PostgreSQL 13 version floor.

How the review tested this

Review: We checked the PostgreSQL 13.0 definition instead of applying the PostgreSQL 12.8 pin to this conditional recommendation. We checked the explicit PostgreSQL 13 condition. Its view definition contains the stated block counters. PostgreSQL 12 absence does not contradict F12.

F14

Verified accurate: “This feature allows users to partially rollback a transaction…”

ACCURATEFactual · partly holds after review

Claim ledger

Article says
This feature allows users to partially rollback a transaction…
What is true
PostgreSQL 18 documentation confirms partial rollback through ROLLBACK TO. It preserves work preceding the savepoint. This citation verifies current documentation, not PostgreSQL 12.8 documentation.

Source

Source · https://www.postgresql.org/docs/current/sql-savepoint.htmlUse ROLLBACK TO to rollback to a savepoint.
In the article · section “What is a subtransaction?”

In the article

excerpt · section “What is a subtransaction?” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

What is a subtransaction?

Subtransaction, also known as "nested transaction", is a transaction started by instruction within the scope of an already started transaction ( definition from Wikipedia ). This feature allows users to partially rollback a transaction, which is helpful in many cases: fewer steps need to be repeated to retry the action if some error occurs.

<savepoint statement> ::= SAVEPOINT <savepoint specifier> <savepoint specifier> ::= <savepoint name> <rollback statement> ::= ROLLBACK [ WORK ] [ AND [ NO ] CHAIN ] [ <savepoint clause> ] <savepoint clause> ::= TO SAVEPOINT <savepoint specifier>
All sources and excerpts · 1
EvidenceUse ROLLBACK TO to rollback to a savepoint.
How the review tested this

Review: The behavior matches the cited page. That page documents PostgreSQL 18, so it does not independently establish publication-time behavior. We checked the documentation header. E-48 describes PostgreSQL 18. It supports current behavior but cannot independently establish the historical confirmation as filed.

F15

Verified accurate: “…ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name…”

ACCURATEFactual · partly holds after review

Claim ledger

Article says
…ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name…
What is true
PostgreSQL 18 documentation permits ROLLBACK TO savepoint_name without SAVEPOINT. The cited synopsis confirms current syntax. It does not independently verify the PostgreSQL 12.8 syntax.

Source

Source · https://www.postgresql.org/docs/current/sql-rollback-to.htmlROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name
In the article · section “What is a subtransaction?”

In the article

excerpt · section “What is a subtransaction?” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

What is a subtransaction?

ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name ( doc )

All sources and excerpts · 1
EvidenceROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name
How the review tested this

Review: The synopsis matches exactly. Its PostgreSQL 18 version limits the historical verification. We checked which release the current URL serves. E-50 documents PostgreSQL 18 syntax. F15 presents a historical confirmation without version-matched evidence.

F16

Verified accurate: “…RELEASE [ SAVEPOINT ] savepoint_name…”

ACCURATEFactual · partly holds after review

Claim ledger

Article says
…RELEASE [ SAVEPOINT ] savepoint_name…
What is true
PostgreSQL 18 documentation permits RELEASE savepoint_name and preserves changes while removing the savepoints. This verifies the current documented behavior. The cited page does not independently establish PostgreSQL 12.8 behavior.

Source

Source · https://www.postgresql.org/docs/current/sql-release-savepoint.htmlRELEASE SAVEPOINT releases the named savepoint and all active savepoints that were created after the named savepoint, and frees their resources.
In the article · section “What is a subtransaction?”

In the article

excerpt · section “What is a subtransaction?” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

What is a subtransaction?

RELEASE [ SAVEPOINT ] savepoint_name ( doc )

All sources and excerpts · 1
EvidenceRELEASE SAVEPOINT releases the named savepoint and all active savepoints that were created after the named savepoint, and frees their resources.
How the review tested this

Review: The page supports optional SAVEPOINT and preserved changes. It documents PostgreSQL 18 rather than the publication-time release. We checked the page version and surrounding syntax. PostgreSQL 18 supports the statement. E-52 does not establish its historical applicability.

F17

Sentry and Mailchimp documented XID wraparound outages

ACCURATEFactual · holds up after review

Claim ledger

Article says
…Sentry , Mailchimp…
What is true
Sentry documented its 2015 XID outage. Mailchimp documented Mandrill entering safety shutdown on February 4, 2019. Both references support the article's wraparound examples.
Charitable reading
The article cites these incidents as wraparound examples without claiming subtransactions caused either incident.

Source

Source · https://blog.sentry.io/transaction-id-wraparound-in-postgres/One such problem caused a major outage of the hosted Sentry service earlier this week. That problem is Postgres’ transaction ID (XID).
In the article · section “Problem 1: XID growth”

In the article

excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 1: XID growth

Subtransactions contribute to the growth of global XID value (32 bit, requiring special automated maintenance usually done by autovacuum). Therefore it implicitly increases risks associated with XID wraparound: if the mentioned maintenance is lagging for some reason and this issue is not resolved, the system may reach a point when the mechanism of transaction ID wraparound protection puts the cluster to the single-user mode causing long-lasting downtime (see examples of how popular SaaS systems were down because of that: Sentry , Mailchimp ). At 1000 writing transactions per second, if each transaction uses 10 subtransactions that each receive an XID, the total consumption is 11,000 XIDs per second: 1000 for the top-level transactions plus 10,000 for their subtransactions. This might not be expected by users – poor autovacuum needs to run in the "transaction ID wraparound prevention" mode more often than it would be if subtransactions had "local" IDs inside each transaction, not "wasting" global XIDs.

All sources and excerpts · 2
EvidenceOne such problem caused a major outage of the hosted Sentry service earlier this week. That problem is Postgres’ transaction ID (XID).
Evidenceat 05:35 UTC on February 4, the XID hit the upper limit and the database went into safety shutdown mode.
How the review tested this

Review: We checked whether wraparound incidents were mistaken for demonstrated subtransaction incidents. The finding makes only the supported wraparound claim. We tested whether F17 attributes these outages to subtransactions. It does not. Both incident accounts support XID-related outages.

F18

Django creates savepoints for nested atomic blocks

ACCURATEFactual · holds up after review

Claim ledger

Article says
…it uses subtransactions by default…
What is true
Django 3.2 creates a savepoint when entering an inner atomic block. The article's nested transaction.atomic example matches that documented default.
Charitable reading
The surrounding example concerns an inner transaction.atomic block inside an existing transaction.

Source

Source · https://docs.djangoproject.com/en/3.2/topics/db/transactions/creates a savepoint when entering an inner atomic block
In the article · section “Problem 3: unexpected use of Multixact IDs”

In the article

excerpt · section “Problem 3: unexpected use of Multixact IDs” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 3: unexpected use of Multixact IDs

In their case, they were using Django; it uses subtransactions by default, so the solution was to disable them entirely:

All sources and excerpts · 1
Evidencecreates a savepoint when entering an inner atomic block
How the review tested this

Review: We checked outermost blocks and savepoint=False. The finding correctly limits its conclusion to the default nested-block behavior. We tested Django's autocommit default against the broader wording. F18 restricts its confirmation to nested atomic blocks. Django 3.2 documents that behavior.

F20

Verified accurate: “…pg_current_xact_id -------------------- 1549100656…”

ACCURATEFactual · partly holds after review

Claim ledger

Article says
…pg_current_xact_id -------------------- 1549100656…
What is true
The displayed XID advances by 4 (derived: 1549100660 − 1549100656). E-59 and E-60 establish this arithmetic. They do not verify tuple headers or execution.

Checked for internal consistency: the evidence is the article itself.

In the article · section “Problem 1: XID growth”

In the article

excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 1: XID growth

test=# create table test1(i int8); CREATE TABLE test=# begin; BEGIN test=*# select pg_current_xact_id(); -- use txid_current() in Postgres 12 or older pg_current_xact_id -------------------- 1549100656 (1 row) test=*# insert into test1 select 1; INSERT 0 1 test=*# savepoint s1; SAVEPOINT test=*# insert into test1 select 2; INSERT 0 1 test=*# savepoint s2; SAVEPOINT test=*# savepoint s3; SAVEPOINT test=*# insert into test1 select 3; INSERT 0 1 test=*# commit; COMMIT test=# select pg_current_xact_id(); pg_current_xact_id -------------------- 1549100660 (1 row) test=# select ctid, xmin, xmax, i from test1; ctid  |    xmin    | xmax | i -------+------------+------+--- (0,1) | 1549100656 |    0 | 1 (0,2) | 1549100657 |    0 | 2 (0,3) | 1549100659 |    0 | 3 (3 rows)
How the review tested this

Review: The two quoted XIDs differ by 4. Neither cited span contains tuple headers. Remove the additional claim that those headers agree with the explanation.

F21

The corrected XID rate includes top-level transactions

ACCURATEFactual · holds up after review

Claim ledger

Article says
…1000 writing transactions per second…
What is true
The workload consumes 11,000 XIDs per second (derived: 1,000 × 11). The total includes 1,000 top-level XIDs and 10,000 subtransaction XIDs.
Charitable reading
The calculation assumes all ten subtransactions receive XIDs, as the corrected sentence specifies.

Checked for internal consistency: the evidence is the article itself.

In the article · section “Problem 1: XID growth”

In the article

excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 1: XID growth

Subtransactions contribute to the growth of global XID value (32 bit, requiring special automated maintenance usually done by autovacuum). Therefore it implicitly increases risks associated with XID wraparound: if the mentioned maintenance is lagging for some reason and this issue is not resolved, the system may reach a point when the mechanism of transaction ID wraparound protection puts the cluster to the single-user mode causing long-lasting downtime (see examples of how popular SaaS systems were down because of that: Sentry , Mailchimp ). At 1000 writing transactions per second, if each transaction uses 10 subtransactions that each receive an XID, the total consumption is 11,000 XIDs per second: 1000 for the top-level transactions plus 10,000 for their subtransactions. This might not be expected by users – poor autovacuum needs to run in the "transaction ID wraparound prevention" mode more often than it would be if subtransactions had "local" IDs inside each transaction, not "wasting" global XIDs.

How the review tested this

Review: We checked whether all ten children receive XIDs. The corrected sentence states that condition and includes the top-level allocation. We recomputed 1,000 × 11 = 11,000 XIDs per second. The corrected sentence requires every child to receive an XID.

F22

Verified accurate: “…32 * 8 * 1024 / 4 = 65536…”

ACCURATEFactual · partly holds after review

Claim ledger

Article says
…32 * 8 * 1024 / 4 = 65536…
What is true
Assuming 32 pages of 8 KiB and 4 bytes per entry, capacity is 65,536 entries across 256 KiB. Each page holds 2,048 entries. This verifies the stated arithmetic, not implementation constants or occupancy.

Checked for internal consistency: the evidence is the article itself.

In the article · section “Problem 4: Subtrans SLRU overflow”

In the article

excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · open in article ↗ (opens in new tab)

Problem 4: Subtrans SLRU overflow

The default buffer size is 8 KiB , and each XID is 4 bytes, so this gives us 32 * 8 * 1024 / 4 = 65536 . The mechanism of filling the Subtrans SLRU can be found in subtrans.c :

/* We need four bytes per xact */ # define SUBTRANS_XACTS_PER_PAGE ( BLCKSZ / sizeof ( TransactionId ) ) # define TransactionIdToPage ( xid ) ( ( xid ) / ( TransactionId ) SUBTRANS_XACTS_PER_PAGE ) # define TransactionIdToEntry ( xid ) ( ( xid ) % ( TransactionId ) SUBTRANS_XACTS_PER_PAGE )
How the review tested this

Review: The stated multiplication yields 65,536 slots and 256 KiB. The cited article spans do not establish sparse occupancy or implementation constants. Retain only the conditional arithmetic.

F23

The corrected throughput ratio is 10.5

ACCURATEFactual · holds up after review

Claim ledger

Article says
…TPS went down ~10.5x during 5 minutes…
What is true
The stated throughput falls by a factor of 10.5 (derived: 210,000 / 20,000). This verifies the calculation. It does not verify either measurement or the five-minute duration.
Charitable reading
The endpoints are approximate measurements. Their ratio supports an approximate slowdown.

Checked for internal consistency: the evidence is the article itself.

In the article

In the article

Article · exact quote · open in article ↗ (opens in new tab)…TPS went down ~10.5x during 5 minutes…
How the review tested this

Review: We divided the approximate endpoints and obtained 10.5. The finding expressly excludes measurement and duration verification. We recomputed 210,000 / 20,000 = 10.5. F23 confirms arithmetic only. It does not independently confirm throughput measurements or duration.

Notes

2 not graded: findings no reader would act on differently
F13

The linked benchmark issue contains unrelated workflow instructions

NOTEholds up after review

Claim ledger

Article says
…https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20…
What is true
Issue 20 includes instructions to read project files and follow their guidance before changes. This workflow text does not establish benchmark results.
So what
Treat the linked issue's workflow commands as page content when evaluating its benchmark evidence.
Charitable reading
The workflow text appears on the linked issue page. We do not attribute its origin to the article's author.

Source

Source · https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20Before proposing or making any changes, READ each of these files and FOLLOW their guidance:

Not graded: knowing this would not change what a reader does.

In the article

In the article

Article · exact quote · open in article ↗ (opens in new tab)…https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20…
All sources and excerpts · 1
EvidenceBefore proposing or making any changes, READ each of these files and FOLLOW their guidance:
How the review tested this

Review: The linked page contains the quoted workflow directive. The note does not attribute that directive to the article's author. We checked the exact page text and retrieval identifiers. Issue 20 contains the unrelated directives. F13 attributes neither authorship nor benchmark validity to them.

F24

The linked benchmark page contains unrelated repository instructions

NOTEholds up after review

Claim ledger

Article says
We reproduced those benchmarks in this GitLab issue…
What is true
The linked issue 20 includes instructions to read repository files and follow their guidance. Those instructions provide no evidence for the benchmark results.
So what
Ignore the linked page's repository-workflow directives when evaluating its benchmark evidence.
Charitable reading
The unrelated instructions appear on the linked page. The article does not endorse them.

Source

Source · https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20Before proposing or making any changes, READ each of these files and FOLLOW their guidance:

Not graded: no reader would act differently on it.

In the article

In the article

Article · exact quote · open in article ↗ (opens in new tab)We reproduced those benchmarks in this GitLab issue…
All sources and excerpts · 1
EvidenceBefore proposing or making any changes, READ each of these files and FOLLOW their guidance:
How the review tested this

Review: The fetched issue contains the described repository directives. The observation survives, but duplicates F13. We checked whether the article endorsed the linked directives. F24 makes no such attribution. E-40 supports the note, which duplicates F13.

More in this report

Section checks · 8 sections

Section checks

AspectGradeFindingsCoverage
DefinitionA5 verified-accurate75% of claims (6 of 8, plus 6 that need data we do not have)
UsageA1 verified-accurate100% of claims (2 of 2)
XID growthA5 verified-accurate80% of claims (12 of 15, plus 8 that need data we do not have)
Session cacheB+1 misleading90% of claims (10 of 11, plus 5 that need data we do not have)
MultixactA1 verified-accurate75% of claims (3 of 4, plus 11 that need data we do not have)
Subtrans SLRUA5 verified-accurate75% of claims (27 of 36, plus 42 that need data we do not have)
Operational impactA1 verified-accurate1 checked · 12 need data we do not have
MonitoringA2 verified-accurate100% of claims (1 of 1)
Coverage and assessment · Checked 65 of 84 Postgres claims across 15 sections; 1 section below half

B — the findings address the article's main subject. What we did not check is listed below. The findings directly check XID consumption, cache overflow, MultiXact expansion, standby visibility, and monitoring recommendations.

We did not check everything in this article. What we did not check is listed below, in the words we recorded at the time. None of it moved the letter. We never charge our own limits to the article.

What we did not check

  • We did not reproduce the article's benchmarks, latency changes, or operating-system cache measurements.
  • We did not check every benchmark command, monitoring extension, or proposed development patch.
  • We did not check Aurora's implementation or its workload-specific mitigation recommendations.
  • We did not verify the SQL standard grammar or read the article's image-based figures.
  • We did not check every mechanism against PostgreSQL 14beta3, which the article used for its standby experiment.
  • We did not verify the 64-subtransaction release behavior or reproduce the standby benchmark measurements.
  • We did not check the AWS quotations, Prime Day account, or proposed patches against their original references.
  • We did not verify the PostgreSQL version introductions against release source.
  • We did not determine which proposed SLRU changes shipped after 2021.
  • We could not reach the SQL standard text or the cited SQLAlchemy, Active Record, and jOOQ documentation.
  • We did not reproduce the throughput, latency, wait-event counts, or CPU profiles the article displays.
  • We did not read the article's embedded demonstrations and performance charts.
  • We did not verify the 50-subtransaction and 100-subtransaction benchmark results.
  • We did not check the claimed quadratic MultiXact work.
  • Section “Development ideas”: we checked 1 of 9 checkable claims.
  • Section “Monitoring”: our checked-claim count (2) exceeds our extracted total (1); the count needs review.
  • We could not decide whether readers can obtain the benchmark environment.
  • We could not decide whether the published benchmark details are complete.
  • We could not decide who measured the benchmark.
  • We hold no source mapping for “postgres-ai/postgresql-consulting”, so we did not check the article's claims about its code.
  • We hold no source mapping for “postgres-ai/docs”, so we did not check the article's claims about its code.
Checked 65 of 84 Postgres claims across 15 sections; 1 section below half
  • Overview: no checkable claims; not counted: 2 product or opinion, 5 not a claim
  • Definition: 6 of 8 Postgres claims checked, plus 6 that need data we do not have; not counted: 1 not a claim; not checked: 2 for other reasons
  • Usage: 2 of 2 Postgres claims checked; not counted: 13 product or opinion, 1 duplicate
  • XID growth: 12 of 15 Postgres claims checked, plus 8 that need data we do not have; not counted: 1 product or opinion, 1 duplicate; not checked: 3 for other reasons
  • Session cache: 10 of 11 Postgres claims checked, plus 5 that need data we do not have; not counted: 2 product or opinion, 1 duplicate, 1 not a claim; not checked: 1 for other reasons
  • Multixact: 3 of 4 Postgres claims checked, plus 11 that need data we do not have; not counted: 8 product or opinion, 1 duplicate, 1 not a claim; not checked: 1 for other reasons
  • Subtrans SLRU: 27 of 36 Postgres claims checked, plus 42 that need data we do not have; not counted: 6 product or opinion, 6 duplicate, 3 not a claim; not checked: 9 for other reasons
  • Operational impact: 1 checked, plus 12 that need data we do not have; not counted: 3 product or opinion, 3 duplicate, 1 not a claim
  • Monitoring: 1 of 1 Postgres claims checked; not counted: 7 product or opinion
  • Detect usage: 1 claim is the author's own account; nothing checkable; not counted: 5 product or opinion
  • Load testing: no checkable claims; not counted: 2 product or opinion
  • Development ideas: 1 of 4 Postgres claims checked, plus 5 that need data we do not have; not counted: 5 product or opinion, 3 duplicate, 1 not a claim; not checked: 3 for other reasons
  • Summary: 1 claim is the author's own account; nothing checkable; not counted: 5 duplicate, 3 not a claim
  • Corrections: 3 of 3 Postgres claims checked; not counted: 6 duplicate, 3 not a claim
  • Footer: no checkable claims; not counted: 1 product or opinion, 3 not a claim

Average of 5 axes: 3.26 · benchmark not reproducible, one step off (source not linked) · result B

Some explanatory text is not shown in this edition; the grade and findings are complete.

Scorecard · the five axes
FACTS scorecard Scorecard radar, 5 axes, bigger is better. Overall B. Factual B+ · 1 wrong of 21 checked · 0 caveats. Applicable A · 0 wrong of 12 checked · 0 caveats. Consistent A · 0 wrong of 21 checked · 0 caveats. Transparent D · 0 wrong of 10 checked · 0 caveats · reproducibility: D (source not linked). Safe A · 0 wrong of 11 checked · 0 caveats. B+ 1 wrong of 21 checked · 0 caveatsFactual B+1 wrong of 210 caveats A 0 wrong of 12 checked · 0 caveatsApplicable A0 wrong of 120 caveats A 0 wrong of 21 checked · 0 caveatsConsistent A0 wrong of 210 caveats D 0 wrong of 10 checked · 0 caveats reproducibility: D (source not linked)Transparent D0 wrong of 100 caveatsreproducibility: D(source not linked) A 0 wrong of 11 checked · 0 caveatsSafe A0 wrong of 110 caveats

By topic: Definition — 5 findings, 0 wrong · Usage — 1 finding, 0 wrong · XID growth — 5 findings, 0 wrong · Session cache — 1 finding, 1 wrong · Multixact — 1 finding, 0 wrong · Subtrans SLRU — 5 findings, 0 wrong · Operational impact — 1 finding, 0 wrong · Monitoring — 2 findings, 0 wrong

Further out is better. Each axis has its own letter, from the wrong claims and caveats among the claims we checked of that kind.

Checked on the FACTS: Factual, Applicable, Consistent, Transparent, Safe. Clockwise: Factual (is it true?), Applicable (does it apply to my setup, today?), Consistent (does it agree with itself?), Transparent (can I check it myself?), Safe (can I run this on prod?).

We checked 21 claims, 30 commands scanned.

AxisLetterWrongCaveatsCheckedCoverage
FactualB+1021assessed: B+ · 1 wrong of 21 checked · 0 caveats
ApplicableA0012assessed: A · 0 wrong of 12 checked · 0 caveats
ConsistentA0021assessed: A · 0 wrong of 21 checked · 0 caveats
TransparentD0010assessed: D · 0 wrong of 10 checked · 0 caveats · reproducibility: D (source not linked)
SafeA0011assessed: A · 0 wrong of 11 checked · 0 caveats
Topics · 8 topics

Topics

TopicFactualApplicableConsistentTransparentSafe
Definition0 issues 5 checked F3 F4 F14 F15 F160 issues 3 checked0 issues 5 checked0 issues 3 checked
Usage0 issues 1 checked F180 issues 1 checked0 issues 1 checked
XID growth0 issues 5 checked F2 F11 F17 F20 F210 issues 3 checked0 issues 5 checked0 issues 4 checked
Session cache1 issue 1 checked F10 issues 1 checked
Multixact0 issues 1 checked F70 issues 1 checked
Subtrans SLRU0 issues 5 checked F5 F6 F9 F22 F230 issues 3 checked0 issues 5 checked0 issues 2 checked
Operational impact0 issues 1 checked F100 issues 1 checked0 issues 1 checked
Monitoring0 issues 2 checked F8 F120 issues 2 checked0 issues 2 checked

Issues found among the claims checked, per topic and axis. Each link goes to the finding behind the count.

Revisions: 2 · B -> B

We audited this article 2 times. Each row is the final edition of one audit. Letters and findings of earlier revisions stay readable at their own address.

  1. Revision 1 · 2026-09-10 03:15 UTC · B · audit version not recorded · regrade version not recorded

    Article as first submitted. 16 accurate · 1 wrong · 2 caveats.

    ElephantSeal: B.

    Changes: First audit. Open: F20 “…TPS went down ~20x during 5 minutes…” (false); F6 “The xmin values in tuples have XID belonging to subtransactions, so each time we read such tuple…” (mostly accurate); F21 “…1000 writing transactions per second, but if they all use 10 subtransactions…” (mostly accurate).

  2. Revision 2 · this page · 2026-10-19 06:39 UTC · B · audited with v1.0.14 (approx.) · regraded with v1.1.1 (approx.)

    Article text changed. 20 accurate · 1 wrong · 0 caveats.

    ElephantSeal: B. Open: the benchmark cannot yet be rerun from what is published.

    Changes: No longer reported: “…TPS went down ~20x during 5 minutes…”; “The xmin values in tuples have XID belonging to subtransactions, so each time we read such tuple…”; “…1000 writing transactions per second, but if they all use 10 subtransactions…”. New: F1 “RELEASE SAVEPOINT does not prevent the 64-XID cache overflow” (misleading).

Questions and answers

Questions and answers

What is pgTrue?

pgTrue is an independent fact-check of technical Postgres articles, made by PostgresAI. It helps you check advice before you use it.

What does the letter grade mean?

The letter grade summarizes the claims we checked. Five axes show what we checked:

  • Factual: is it true?
  • Applicable: does it apply to my setup, today?
  • Consistent: does it agree with itself?
  • Transparent: can I check it myself?
  • Safe: can I run this in production?

What is the ElephantSeal?

The ElephantSeal is the mark an article earns. It always shows the latest edition. “Open:” lists what is still open.

Can an author reply?

Authors can ask us to correct a finding, reply to it, or withdraw it. Right-of-reply policy.

Paste into your AI assistant to fix the article, then ask for a re-review.

Show the text
Fix the article with this report, then ask pgTrue for a re-review.

# pgTrue report: PostgreSQL subtransactions considered harmful

Article title: PostgreSQL subtransactions considered harmful
Article URL: https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful
Report URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c
Audited revision: 2 of 2, 2026-10-19 06:39:00 UTC
Overall letter: B

## Axes

- Factual: B+ · 1 wrong · 21 checked · 0 caveats · assessed
- Applicable: A · 0 wrong · 12 checked · 0 caveats · assessed
- Consistent: A · 0 wrong · 21 checked · 0 caveats · assessed
- Transparent: D · 0 wrong · 10 checked · 0 caveats · assessed
- Safe: A · 0 wrong · 11 checked · 0 caveats · assessed

ElephantSeal: B.
Open conditions: the benchmark cannot yet be rerun from what is published.

## Report metadata

- Report: Technical fact-check, edition 3
- Issued: 2026-10-19
- Edition: Updated after review. Corrections are listed below.
- Submitted: Submitted by the PostgresAI team.
- Author response: No written reply from the author. The article changed 1 time after our first audit; we re-audited each version. See Revisions below. Policy: [right-of-reply and corrections policy](/pgtrue/security).
- pgTrue version: audited with v1.0.14 (approx.) · regraded with v1.1.1 (approx.)

## Findings needing a change (1)

### F1 · Misleading · Factual · RELEASE SAVEPOINT does not prevent the 64-XID cache overflow
Location: excerpt · section “Problem 2: per-session cache overflow” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=no%20degradation%20happens%20when%20passing%20the%20threshold%20defined%20by%20PGPROC_MAX_CACHED_SUBXIDS)
Article says:
```text
…no degradation happens when passing the threshold defined by PGPROC_MAX_CACHED_SUBXIDS…
```
What is true:
Released children remain non-aborted children until the top-level transaction ends. xact.c:4814-4816 retains their XIDs, and varsup.c:227-234 sets overflow on the next uncached child. A nesting depth of 1 can exceed 64 child XIDs. Relying on RELEASE can waste mitigation work.
So what:
Limit assigned, non-aborted child XIDs per top-level transaction. Split large transactions instead of relying on RELEASE SAVEPOINT.
Charitable reading:
The reported benchmark can show no measurable slowdown. That observation does not establish that RELEASE SAVEPOINT prevents overflow.
Review: The benchmark could show no degradation. That does not establish that RELEASE prevents overflow. Retained child XIDs support the mitigation warning. We tested the charitable reading that RELEASE produced no measurable slowdown. F1 preserves that possibility. The source supports retained child XIDs and overflow after 64 cached children. Splitting transactions names a concrete mitigation. Wasted work matches the evidence.

Sources:
- [REL_12_8 · src/include/storage/proc.h:25-36](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/include/storage/proc.h#L25-L36)
  Excerpt:
  ```text
  * Each backend advertises up to PGPROC_MAX_CACHED_SUBXIDS TransactionIds
 * for non-aborted subtransactions of its current top transaction.  These
 * have to be treated as running XIDs by other backends.
  ```
- [REL_12_8 · src/backend/access/transam/varsup.c:224-234](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/varsup.c#L224-L234)
  Excerpt:
  ```text
  if (nxids < PGPROC_MAX_CACHED_SUBXIDS)
		{
			MyProc->subxids.xids[nxids] = xid;
			pg_write_barrier();
			MyPgXact->nxids = nxids + 1;
		}
		else
			MyPgXact->overflowed = true;
  ```
- [REL_12_8 · src/backend/access/transam/xact.c:1517-1552](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/xact.c#L1517-L1552)
  Excerpt:
  ```text
  * Pass my own XID and my child XIDs up to my parent as committed children.
  ```
- [REL_12_8 · src/include/storage/proc.h:25-36](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/include/storage/proc.h#L25-L36)
  Excerpt:
  ```text
  #define PGPROC_MAX_CACHED_SUBXIDS 64	/* XXX guessed-at value */
  ```
- [REL_12_8 · src/backend/access/transam/xact.c:4814-4817](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/xact.c#L4814-L4817)
  Excerpt:
  ```text
  /* Post-commit cleanup */
	if (FullTransactionIdIsValid(s->fullTransactionId))
		AtSubCommit_childXids();
	AfterTriggerEndSubXact(true);
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F1

## Verified accurate claims (20)

### F2 · Accurate · Factual · XID assignment also assigns unidentified ancestors
Location: excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=all%20of%20them%20get%20their%20own%20XID%20assigned)
Article says:
```text
…all of them get their own XID assigned…
```
What is true:
AssignTransactionId assigns XIDs to ancestors before assigning the child. PostgreSQL 12.8 documents this invariant in xact.c:548-552.
Charitable reading:
The sentence applies to ancestors of an innermost subtransaction that receives an XID.
Review: We checked the innermost-write hypothesis. AssignTransactionId explicitly assigns previously unidentified ancestors. We checked whether F2 extended assignment to unrelated children. It restricts the claim to ancestors. xact.c confirms that invariant.

Sources:
- [REL_12_8 · src/backend/access/transam/xact.c:548-552](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/xact.c#L548-L552)
  Excerpt:
  ```text
  * Also, any parent TransactionStates that don't yet have XIDs are assigned
 * one; this maintains the invariant that a child transaction has an XID
 * following its parent's.
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F2

### F3 · Accurate · Factual · PL/pgSQL exception blocks create subtransactions
Location: excerpt · section “Who is using subtransactions?” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=BEGIN%20%2F%20EXCEPTION%20WHEN%20..,END%20blocks%20in%20PL%2FpgSQL%20code)
Article says:
```text
…BEGIN / EXCEPTION WHEN .. / END blocks in PL/pgSQL code…
```
What is true:
pl_exec.c:1683-1707 executes an exception block inside an internal subtransaction. PostgreSQL 12.8 documents the same behavior in plpgsql.sgml:310-313.
Charitable reading:
The article names blocks containing EXCEPTION, rather than ordinary BEGIN/END blocks.
Review: We tested whether ordinary blocks were conflated with exception blocks. Both the quotation and implementation require an EXCEPTION clause. We checked the distinction between ordinary blocks and exception blocks. pl_exec.c starts an internal subtransaction only in the exception branch.

Sources:
- [REL_12_8 · doc/src/sgml/plpgsql.sgml:305-314](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/plpgsql.sgml#L305-L314)
  Excerpt:
  ```text
  Also, a block containing an <literal>EXCEPTION</literal> clause effectively
     forms a subtransaction that can be rolled back without affecting the
     outer transaction.  For more about that see <xref
     linkend="plpgsql-error-trapping"/>.
  ```
- [REL_12_8 · src/pl/plpgsql/src/pl_exec.c:1683-1708](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/pl/plpgsql/src/pl_exec.c#L1683-L1708)
  Excerpt:
  ```text
  if (block->exceptions)
	{
		/*
		 * Execute the statements in the block's body inside a sub-transaction
		 */
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F3

### F4 · Accurate · Factual · PL/Python supports explicit subtransaction contexts
Location: excerpt · section “Who is using subtransactions?” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=plpy.subtransaction%28%29%20in%20PL%2FPython%20code)
Article says:
```text
…plpy.subtransaction() in PL/Python code…
```
What is true:
plpython.sgml:1294-1298 documents plpy.subtransaction(). Its context-entry implementation calls BeginInternalSubTransaction in plpy_subxactobject.c:117.
Charitable reading:
The function supplies a context manager. Entering that context starts the subtransaction.
Review: Creating the helper and entering its context differ. The finding correctly attributes transaction creation to context entry. We tested whether calling the constructor alone starts a subtransaction. F4 correctly identifies context entry as the operative step.

Sources:
- [REL_12_8 · src/pl/plpython/plpy_subxactobject.c:108-120](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/pl/plpython/plpy_subxactobject.c#L108-L120)
  Excerpt:
  ```text
  BeginInternalSubTransaction(NULL);
  ```
- [REL_12_8 · doc/src/sgml/plpython.sgml:1294-1299](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/plpython.sgml#L1294-L1299)
  Excerpt:
  ```text
  subtransaction.  The <literal>plpy</literal> module provides a
    helper object to manage explicit subtransactions that gets created
    with the <literal>plpy.subtransaction()</literal> function.
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F4

### F5 · Accurate · Factual · The revised standby lookup conditions match PostgreSQL 12.8
Location: excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=look%20up%20their%20top%2Dlevel%20parent%20in%20pg_subtrans)
Article says:
```text
…look up their top-level parent in pg_subtrans…
```
What is true:
snapmgr.c:2253-2258 returns before parent lookup for XIDs outside \[xmin, xmax). The recovery branch calls SubTransGetTopmostTransaction when suboverflowed is set. That branch accepts both top-level and child XIDs.
Charitable reading:
The article explicitly conditions lookup on recovery snapshots, suboverflowed, and the xmin-to-xmax range.
Review: We checked both range boundaries and the recovery branch. The revised explanation includes their conditions and covers top-level XIDs. We checked both range boundaries and the recovery branch. The revised article includes those conditions. F5 does not endorse the removed universal explanation.

Sources:
- [REL_12_8 · src/backend/utils/time/snapmgr.c:2253-2258](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/utils/time/snapmgr.c#L2253-L2258)
  Excerpt:
  ```text
  /* Any xid < xmin is not in-progress */
	if (TransactionIdPrecedes(xid, snapshot->xmin))
		return false;
	/* Any xid >= xmax is in-progress */
	if (TransactionIdFollowsOrEquals(xid, snapshot->xmax))
		return true;
  ```
- [REL_12_8 · src/backend/utils/time/snapmgr.c:2308-2338](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/utils/time/snapmgr.c#L2308-L2338)
  Excerpt:
  ```text
  if (snapshot->suboverflowed)
		{
			/*
			 * Snapshot overflowed, so convert xid to top-level.  This is safe
			 * because we eliminated too-old XIDs above.
			 */
			xid = SubTransGetTopmostTransaction(xid);
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F5

### F6 · Accurate · Factual · The default Subtrans cache contains 32 pages
Location: excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=NUM_SUBTRANS_BUFFERS%2032)
Article says:
```text
…NUM_SUBTRANS_BUFFERS 32…
```
What is true:
PostgreSQL 12.8 defines 32 Subtrans buffers and 4-byte TransactionIds. Default BLCKSZ is 8 KiB. The cache covers 65,536 XID positions (derived: 32 × 8,192 / 4). subtrans.c:52-55 maps global XID positions to pages and entries.
Charitable reading:
The 65,536-entry calculation assumes the default 8 KiB build.
Review: We checked configurable block size and sparse occupancy. The finding specifies the default build and counts positions, not occupied children. We tested custom block sizes and sparse entries. F6 specifies the default build and counts XID positions. The constants yield 65,536 positions.

Sources:
- [REL_12_8 · src/include/access/subtrans.h:13-16](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/include/access/subtrans.h#L13-L16)
  Excerpt:
  ```text
  #define NUM_SUBTRANS_BUFFERS	32
  ```
- [REL_12_8 · src/backend/access/transam/subtrans.c:50-55](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/subtrans.c#L50-L55)
  Excerpt:
  ```text
  /* We need four bytes per xact */
#define SUBTRANS_XACTS_PER_PAGE (BLCKSZ / sizeof(TransactionId))

#define TransactionIdToPage(xid) ((xid) / (TransactionId) SUBTRANS_XACTS_PER_PAGE)
#define TransactionIdToEntry(xid) ((xid) % (TransactionId) SUBTRANS_XACTS_PER_PAGE)
  ```
- [REL_12_8 · configure.in:250-258](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/configure.in#L250-L258)
  Excerpt:
  ```text
  PGAC_ARG_REQ(with, blocksize, [BLOCKSIZE], [set table block size in kB [8]],
             [blocksize=$withval],
             [blocksize=8])
  ```
- [REL_12_8 · src/include/c.h:519-519](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/include/c.h#L519-L519)
  Excerpt:
  ```text
  typedef uint32 TransactionId;
  ```
- [REL_12_8 · src/backend/access/transam/subtrans.c:318-351](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/subtrans.c#L318-L351)
  Qualification: Version note: The pin names the control lock SubtransControlLock.
  Excerpt:
  ```text
  if (TransactionIdToEntry(newestXact) != 0 &&
		!TransactionIdEquals(newestXact, FirstNormalTransactionId))
		return;
  ```
- [REL_12_8 · src/backend/access/transam/slru.c:1-30](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/slru.c#L1-L30)
  Excerpt:
  ```text
  * We use a simple least-recently-used scheme to manage a pool of page
 * buffers.  Under ordinary circumstances we expect that write
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F6

### F7 · Accurate · Factual · MultiXact expansion creates a replacement identifier
Location: excerpt · section “Problem 3: unexpected use of Multixact IDs” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=entries%20are%20immutable)
Article says:
```text
…entries are immutable…
```
What is true:
multixact.c:424-426 states that expansion creates another MultiXact instead of changing existing membership. The implementation copies still-relevant members before adding the new member.
Charitable reading:
The surrounding example concerns concurrent lockers whose memberships remain relevant.
Review: An already-present member can return the existing identifier. That exception does not contradict immutability when membership actually expands. We checked whether an existing member always forces expansion. The source permits returning the existing identifier. F7 concerns adding new membership and preserves that distinction.

Sources:
- [REL_12_8 · src/backend/access/transam/multixact.c:418-426](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/access/transam/multixact.c#L418-L426)
  Excerpt:
  ```text
  * Note that we do NOT actually modify the membership of a pre-existing
 * MultiXactId; instead we create a new one.  This is necessary to avoid
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F7

### F8 · Accurate · Factual · pg_stat_activity exposes current wait events for sampling
Location: excerpt · section “Recommendation 1: good monitoring” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=using%20periodical%20sampling%20of%20pg_stat_activity)
Article says:
```text
…using periodical sampling of pg_stat_activity…
```
What is true:
PostgreSQL 12.8 exposes wait_event_type and wait_event through pg_stat_activity. monitoring.sgml:769 identifies wait_event as the current wait, or NULL. External sampling must retain historical observations.
Charitable reading:
Periodic sampling collects observations over time. The view itself does not retain history.
Review: We checked whether current wait fields establish historical monitoring. The finding correctly requires external retention. We tested whether pg_stat_activity retains historical waits. F8 explicitly requires external retention. The view exposes the current wait fields.

Sources:
- [REL_12_8 · src/backend/catalog/system_views.sql:732-756](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/catalog/system_views.sql#L732-L756)
  Excerpt:
  ```text
  S.wait_event_type,
            S.wait_event,
  ```
- [REL_12_8 · doc/src/sgml/monitoring.sgml:767-776](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/monitoring.sgml#L767-L776)
  Excerpt:
  ```text
  <entry>Wait event name if backend is currently waiting, otherwise NULL.
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F8

### F9 · Accurate · Factual · The sleep-and-watch recipe creates the described transaction cadence
Location: excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=pg_sleep_for%20%28%20%275%20minutes%27%20%29)
Article says:
```text
…pg_sleep_for ( '5 minutes' )…
```
What is true:
pg_sleep_for accepts an interval and sleeps for that interval. txid_current assigns a top-level XID when needed. psql's documented watch interval waits between executions. The article's 300-second interval adds a five-minute break after each five-minute query.
Charitable reading:
The SQL holds its implicit transaction while sleeping. The watch interval applies between executions.
Review: We checked interval units and whether watch waits between executions. PostgreSQL 12.8 documentation supports the stated cadence. We checked whether the 300-second interval includes query execution. PostgreSQL 12 documentation specifies waiting between executions. txid_current assigns an XID when needed.

Sources:
- [REL_12_8 · src/include/catalog/pg_proc.dat:6085-6088](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/include/catalog/pg_proc.dat#L6085-L6088)
  Excerpt:
  ```text
  { oid => '3935', descr => 'sleep for the specified interval',
  proname => 'pg_sleep_for', prolang => 'sql', provolatile => 'v',
  prorettype => 'void', proargtypes => 'interval',
  ```
- [REL_12_8 · doc/src/sgml/ref/psql-ref.sgml:3245-3257](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/ref/psql-ref.sgml#L3245-L3257)
  Excerpt:
  ```text
  until interrupted or the query fails.  Wait the specified number of
        seconds (default 2) between executions.  Each query result is
  ```
- [REL_12_8 · doc/src/sgml/func.sgml:19523-19533](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/func.sgml#L19523-L19533)
  Excerpt:
  ```text
  <entry><literal><function>txid_current()</function></literal></entry>
       <entry><type>bigint</type></entry>
       <entry>get current transaction ID, assigning a new one if the current transaction does not have one</entry>
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F9

### F10 · Accurate · Factual · statement_timeout can cancel statements slowed by contention
Location: excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=statement_timeout)
Article says:
```text
…statement_timeout…
```
What is true:
PostgreSQL 12.8 aborts statements exceeding a positive statement_timeout. postgres.c:4716-4721 arms the timer only when the setting exceeds 0. The default 0 disables this timeout.
Charitable reading:
The article describes configured production timeouts, rather than claiming that statement_timeout is enabled by default.
Review: We checked whether the timeout was presented as enabled by default. The finding explicitly states that zero disables it. We tested the disabled default as a counterexample. F10 specifies a positive setting. The timer and documentation support cancellation.

Sources:
- [REL_12_8 · doc/src/sgml/config.sgml:7888-7918](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/config.sgml#L7888-L7918)
  Excerpt:
  ```text
  Abort any statement that takes more than the specified amount of time.
  ```
- [REL_12_8 · src/backend/tcop/postgres.c:4704-4727](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/src/backend/tcop/postgres.c#L4704-L4727)
  Excerpt:
  ```text
  if (StatementTimeout > 0)
	{
		if (!stmt_timeout_active)
		{
			enable_timeout_after(STATEMENT_TIMEOUT, StatementTimeout);
			stmt_timeout_active = true;
		}
	}
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F10

### F11 · Accurate · Factual · The transaction-ID example provides the PostgreSQL 12 fallback
Location: excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=use%20txid_current%28%29%20in%20Postgres%2012%20or%20older)
Article says:
```text
…use txid_current() in Postgres 12 or older…
```
What is true:
PostgreSQL 12.8 documents txid_current(), including its XID-allocation behavior. PostgreSQL 13.0 defines pg_current_xact_id in pg_proc.dat:9579-9582. The article distinguishes these versions.
Charitable reading:
The article supplies an explicit PostgreSQL 12 fallback for its newer function name.
Review: We checked both release pins. PostgreSQL 13.0 contains the newer name, and PostgreSQL 12.8 documents the explicit fallback. We checked both release identifiers. The PostgreSQL 13 citation defines the newer name. PostgreSQL 12 documents the stated fallback.

Sources:
- [REL_13_0 · src/include/catalog/pg_proc.dat:9579-9582](https://github.com/postgres/postgres/blob/29be9983a64c011eac0b9ee29895cce71e15ea77/src/include/catalog/pg_proc.dat#L9579-L9582)
  Qualification: Version note: Checked PostgreSQL 13.0 for the newer function name.
  Excerpt:
  ```text
  proname => 'pg_current_xact_id', provolatile => 's', proparallel => 'u',
  prorettype => 'xid8', proargtypes => '', prosrc => 'pg_current_xact_id' },
  ```
- [REL_12_8 · doc/src/sgml/func.sgml:19523-19533](https://github.com/postgres/postgres/blob/de835071fda945fb5e40340d3ea8dd2ca13e725c/doc/src/sgml/func.sgml#L19523-L19533)
  Excerpt:
  ```text
  <entry><literal><function>txid_current()</function></literal></entry>
       <entry><type>bigint</type></entry>
       <entry>get current transaction ID, assigning a new one if the current transaction does not have one</entry>
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F11

### F12 · Accurate · Factual · PostgreSQL 13 provides pg_stat_slru block counters
Location: excerpt · section “Recommendation 1: good monitoring” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=if%20PostgreSQL%20version%20is%2013%20or%20newer)
Article says:
```text
…if PostgreSQL version is 13 or newer…
```
What is true:
PostgreSQL 13.0 defines pg_stat_slru in system_views.sql:793 onward. The view includes each SLRU's name, block hits, block reads, and block writes.
Charitable reading:
The monitoring recommendation explicitly requires PostgreSQL 13 or newer.
Review: We checked the PostgreSQL 13.0 definition instead of applying the PostgreSQL 12.8 pin to this conditional recommendation. We checked the explicit PostgreSQL 13 condition. Its view definition contains the stated block counters. PostgreSQL 12 absence does not contradict F12.

Sources:
- [REL_13_0 · src/backend/catalog/system_views.sql:793-799](https://github.com/postgres/postgres/blob/29be9983a64c011eac0b9ee29895cce71e15ea77/src/backend/catalog/system_views.sql#L793-L799)
  Qualification: Version note: Checked the article's PostgreSQL 13 version floor.
  Excerpt:
  ```text
  CREATE VIEW pg_stat_slru AS
    SELECT
            s.name,
            s.blks_zeroed,
            s.blks_hit,
            s.blks_read,
            s.blks_written,
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F12

### F14 · Accurate · Factual · Verified accurate: “This feature allows users to partially rollback a transaction…”
Location: excerpt · section “What is a subtransaction?” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=This%20feature%20allows%20users%20to%20partially%20rollback%20a%20transaction)
Article says:
```text
This feature allows users to partially rollback a transaction…
```
What is true:
PostgreSQL 18 documentation confirms partial rollback through ROLLBACK TO. It preserves work preceding the savepoint. This citation verifies current documentation, not PostgreSQL 12.8 documentation.
Review: The behavior matches the cited page. That page documents PostgreSQL 18, so it does not independently establish publication-time behavior. We checked the documentation header. E-48 describes PostgreSQL 18. It supports current behavior but cannot independently establish the historical confirmation as filed.

Sources:
- [https://www.postgresql.org/docs/current/sql-savepoint.html](https://www.postgresql.org/docs/current/sql-savepoint.html)
  Excerpt:
  ```text
  Use ROLLBACK TO to rollback to a savepoint.
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F14

### F15 · Accurate · Factual · Verified accurate: “…ROLLBACK \[ WORK \| TRANSACTION \] TO \[ SAVEPOINT \] savepoint_name…”
Location: excerpt · section “What is a subtransaction?” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=ROLLBACK%20%5B%20WORK%20%7C%20TRANSACTION,TO%20%5B%20SAVEPOINT%20%5D%20savepoint_name)
Article says:
```text
…ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name…
```
What is true:
PostgreSQL 18 documentation permits ROLLBACK TO savepoint_name without SAVEPOINT. The cited synopsis confirms current syntax. It does not independently verify the PostgreSQL 12.8 syntax.
Review: The synopsis matches exactly. Its PostgreSQL 18 version limits the historical verification. We checked which release the current URL serves. E-50 documents PostgreSQL 18 syntax. F15 presents a historical confirmation without version-matched evidence.

Sources:
- [https://www.postgresql.org/docs/current/sql-rollback-to.html](https://www.postgresql.org/docs/current/sql-rollback-to.html)
  Excerpt:
  ```text
  ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F15

### F16 · Accurate · Factual · Verified accurate: “…RELEASE \[ SAVEPOINT \] savepoint_name…”
Location: excerpt · section “What is a subtransaction?” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=RELEASE%20%5B%20SAVEPOINT%20%5D%20savepoint_name)
Article says:
```text
…RELEASE [ SAVEPOINT ] savepoint_name…
```
What is true:
PostgreSQL 18 documentation permits RELEASE savepoint_name and preserves changes while removing the savepoints. This verifies the current documented behavior. The cited page does not independently establish PostgreSQL 12.8 behavior.
Review: The page supports optional SAVEPOINT and preserved changes. It documents PostgreSQL 18 rather than the publication-time release. We checked the page version and surrounding syntax. PostgreSQL 18 supports the statement. E-52 does not establish its historical applicability.

Sources:
- [https://www.postgresql.org/docs/current/sql-release-savepoint.html](https://www.postgresql.org/docs/current/sql-release-savepoint.html)
  Excerpt:
  ```text
  RELEASE SAVEPOINT releases the named savepoint and all active savepoints that were created after the named savepoint, and frees their resources.
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F16

### F17 · Accurate · Factual · Sentry and Mailchimp documented XID wraparound outages
Location: excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=Sentry%20%2C%20Mailchimp)
Article says:
```text
…Sentry , Mailchimp…
```
What is true:
Sentry documented its 2015 XID outage. Mailchimp documented Mandrill entering safety shutdown on February 4, 2019. Both references support the article's wraparound examples.
Charitable reading:
The article cites these incidents as wraparound examples without claiming subtransactions caused either incident.
Review: We checked whether wraparound incidents were mistaken for demonstrated subtransaction incidents. The finding makes only the supported wraparound claim. We tested whether F17 attributes these outages to subtransactions. It does not. Both incident accounts support XID-related outages.

Sources:
- [https://blog.sentry.io/transaction-id-wraparound-in-postgres/](https://blog.sentry.io/transaction-id-wraparound-in-postgres/)
  Excerpt:
  ```text
  One such problem caused a major outage of the hosted Sentry service earlier this week. That problem is Postgres’ transaction ID (XID).
  ```
- [https://mailchimp.com/what-we-learned-from-the-recent-mandrill-outage/](https://mailchimp.com/what-we-learned-from-the-recent-mandrill-outage/)
  Excerpt:
  ```text
  at 05:35 UTC on February 4, the XID hit the upper limit and the database went into safety shutdown mode.
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F17

### F18 · Accurate · Factual · Django creates savepoints for nested atomic blocks
Location: excerpt · section “Problem 3: unexpected use of Multixact IDs” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=it%20uses%20subtransactions%20by%20default)
Article says:
```text
…it uses subtransactions by default…
```
What is true:
Django 3.2 creates a savepoint when entering an inner atomic block. The article's nested transaction.atomic example matches that documented default.
Charitable reading:
The surrounding example concerns an inner transaction.atomic block inside an existing transaction.
Review: We checked outermost blocks and savepoint=False. The finding correctly limits its conclusion to the default nested-block behavior. We tested Django's autocommit default against the broader wording. F18 restricts its confirmation to nested atomic blocks. Django 3.2 documents that behavior.

Sources:
- [https://docs.djangoproject.com/en/3.2/topics/db/transactions/](https://docs.djangoproject.com/en/3.2/topics/db/transactions/)
  Excerpt:
  ```text
  creates a savepoint when entering an inner atomic block
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F18

### F20 · Accurate · Factual · Verified accurate: “…pg_current_xact_id -------------------- 1549100656…”
Location: excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=pg_current_xact_id%20%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%2D%201549100656)
Article says:
```text
…pg_current_xact_id -------------------- 1549100656…
```
What is true:
The displayed XID advances by 4 (derived: 1549100660 − 1549100656). E-59 and E-60 establish this arithmetic. They do not verify tuple headers or execution.
Explanation: Checked for internal consistency: the evidence is the article itself.
Review: The two quoted XIDs differ by 4. Neither cited span contains tuple headers. Remove the additional claim that those headers agree with the explanation.

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F20

### F21 · Accurate · Factual · The corrected XID rate includes top-level transactions
Location: excerpt · section “Problem 1: XID growth” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=1000%20writing%20transactions%20per%20second)
Article says:
```text
…1000 writing transactions per second…
```
What is true:
The workload consumes 11,000 XIDs per second (derived: 1,000 × 11). The total includes 1,000 top-level XIDs and 10,000 subtransaction XIDs.
Charitable reading:
The calculation assumes all ten subtransactions receive XIDs, as the corrected sentence specifies.
Explanation: Checked for internal consistency: the evidence is the article itself.
Review: We checked whether all ten children receive XIDs. The corrected sentence states that condition and includes the top-level allocation. We recomputed 1,000 × 11 = 11,000 XIDs per second. The corrected sentence requires every child to receive an XID.

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F21

### F22 · Accurate · Factual · Verified accurate: “…32 \* 8 \* 1024 / 4 = 65536…”
Location: excerpt · section “Problem 4: Subtrans SLRU overflow” · as fetched 2026-10-19 · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=32%20%2A%208%20%2A%201024%20%2F%204%20%3D%2065536)
Article says:
```text
…32 * 8 * 1024 / 4 = 65536…
```
What is true:
Assuming 32 pages of 8 KiB and 4 bytes per entry, capacity is 65,536 entries across 256 KiB. Each page holds 2,048 entries. This verifies the stated arithmetic, not implementation constants or occupancy.
Explanation: Checked for internal consistency: the evidence is the article itself.
Review: The stated multiplication yields 65,536 slots and 256 KiB. The cited article spans do not establish sparse occupancy or implementation constants. Retain only the conditional arithmetic.

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F22

### F23 · Accurate · Factual · The corrected throughput ratio is 10.5
Location: Article · exact quote · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=TPS%20went%20down%20~10.5x%20during%205%20minutes)
Article says:
```text
…TPS went down ~10.5x during 5 minutes…
```
What is true:
The stated throughput falls by a factor of 10.5 (derived: 210,000 / 20,000). This verifies the calculation. It does not verify either measurement or the five-minute duration.
Charitable reading:
The endpoints are approximate measurements. Their ratio supports an approximate slowdown.
Explanation: Checked for internal consistency: the evidence is the article itself.
Review: We divided the approximate endpoints and obtained 10.5. The finding expressly excludes measurement and duration verification. We recomputed 210,000 / 20,000 = 10.5. F23 confirms arithmetic only. It does not independently confirm throughput measurements or duration.

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F23

## Notes (not graded) (2)

### F13 · Note ·  · The linked benchmark issue contains unrelated workflow instructions
Location: Article · exact quote · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=https%3A%2F%2Fgitlab.com%2Fpostgres%2Dai%2Fpostgresql%2Dconsulting%2Ftests%2Dand%2Dbenchmarks%2F%2D%2Fissues%2F20)
Article says:
```text
…https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20…
```
What is true:
Issue 20 includes instructions to read project files and follow their guidance before changes. This workflow text does not establish benchmark results.
So what:
Treat the linked issue's workflow commands as page content when evaluating its benchmark evidence.
Charitable reading:
The workflow text appears on the linked issue page. We do not attribute its origin to the article's author.
Explanation: Not graded: knowing this would not change what a reader does.
Review: The linked page contains the quoted workflow directive. The note does not attribute that directive to the article's author. We checked the exact page text and retrieval identifiers. Issue 20 contains the unrelated directives. F13 attributes neither authorship nor benchmark validity to them.

Sources:
- [https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20](https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20)
  Excerpt:
  ```text
  Before proposing or making any changes, READ each of these files and FOLLOW their guidance:
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F13

### F24 · Note ·  · The linked benchmark page contains unrelated repository instructions
Location: Article · exact quote · [open in article](https://postgres.ai/blog/20210831-postgresql-subtransactions-considered-harmful#:~:text=We%20reproduced%20those%20benchmarks%20in%20this%20GitLab%20issue)
Article says:
```text
We reproduced those benchmarks in this GitLab issue…
```
What is true:
The linked issue 20 includes instructions to read repository files and follow their guidance. Those instructions provide no evidence for the benchmark results.
So what:
Ignore the linked page's repository-workflow directives when evaluating its benchmark evidence.
Charitable reading:
The unrelated instructions appear on the linked page. The article does not endorse them.
Explanation: Not graded: no reader would act differently on it.
Review: The fetched issue contains the described repository directives. The observation survives, but duplicates F13. We checked whether the article endorsed the linked directives. F24 makes no such attribution. E-40 supports the note, which duplicates F13.

Sources:
- [https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20](https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20)
  Excerpt:
  ```text
  Before proposing or making any changes, READ each of these files and FOLLOW their guidance:
  ```

Finding URL: https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c#F24

## Withdrawn findings (0)

None.

## Section checks

- Definition · A · 5 verified-accurate · 75% of claims (6 of 8, plus 6 that need data we do not have)
- Usage · A · 1 verified-accurate · 100% of claims (2 of 2)
- XID growth · A · 5 verified-accurate · 80% of claims (12 of 15, plus 8 that need data we do not have)
- Session cache · B+ · 1 misleading · 90% of claims (10 of 11, plus 5 that need data we do not have)
- Multixact · A · 1 verified-accurate · 75% of claims (3 of 4, plus 11 that need data we do not have)
- Subtrans SLRU · A · 5 verified-accurate · 75% of claims (27 of 36, plus 42 that need data we do not have)
- Operational impact · A · 1 verified-accurate · 1 checked · 12 need data we do not have
- Monitoring · A · 2 verified-accurate · 100% of claims (1 of 1)

## Claim coverage

- Overview: no checkable claims; not counted: 2 product or opinion, 5 not a claim
- Definition: 6 of 8 Postgres claims checked, plus 6 that need data we do not have; not counted: 1 not a claim; not checked: 2 for other reasons
- Usage: 2 of 2 Postgres claims checked; not counted: 13 product or opinion, 1 duplicate
- XID growth: 12 of 15 Postgres claims checked, plus 8 that need data we do not have; not counted: 1 product or opinion, 1 duplicate; not checked: 3 for other reasons
- Session cache: 10 of 11 Postgres claims checked, plus 5 that need data we do not have; not counted: 2 product or opinion, 1 duplicate, 1 not a claim; not checked: 1 for other reasons
- Multixact: 3 of 4 Postgres claims checked, plus 11 that need data we do not have; not counted: 8 product or opinion, 1 duplicate, 1 not a claim; not checked: 1 for other reasons
- Subtrans SLRU: 27 of 36 Postgres claims checked, plus 42 that need data we do not have; not counted: 6 product or opinion, 6 duplicate, 3 not a claim; not checked: 9 for other reasons
- Operational impact: 1 checked, plus 12 that need data we do not have; not counted: 3 product or opinion, 3 duplicate, 1 not a claim
- Monitoring: 1 of 1 Postgres claims checked; not counted: 7 product or opinion
- Detect usage: 1 claim is the author's own account; nothing checkable; not counted: 5 product or opinion
- Load testing: no checkable claims; not counted: 2 product or opinion
- Development ideas: 1 of 4 Postgres claims checked, plus 5 that need data we do not have; not counted: 5 product or opinion, 3 duplicate, 1 not a claim; not checked: 3 for other reasons
- Summary: 1 claim is the author's own account; nothing checkable; not counted: 5 duplicate, 3 not a claim
- Corrections: 3 of 3 Postgres claims checked; not counted: 6 duplicate, 3 not a claim
- Footer: no checkable claims; not counted: 1 product or opinion, 3 not a claim

## What we did not check

- We did not reproduce the article's benchmarks, latency changes, or operating-system cache measurements.
- We did not check every benchmark command, monitoring extension, or proposed development patch.
- We did not check Aurora's implementation or its workload-specific mitigation recommendations.
- We did not verify the SQL standard grammar or read the article's image-based figures.
- We did not check every mechanism against PostgreSQL 14beta3, which the article used for its standby experiment.
- We did not verify the 64-subtransaction release behavior or reproduce the standby benchmark measurements.
- We did not check the AWS quotations, Prime Day account, or proposed patches against their original references.
- We did not verify the PostgreSQL version introductions against release source.
- We did not determine which proposed SLRU changes shipped after 2021.
- We could not reach the SQL standard text or the cited SQLAlchemy, Active Record, and jOOQ documentation.
- We did not reproduce the throughput, latency, wait-event counts, or CPU profiles the article displays.
- We did not read the article's embedded demonstrations and performance charts.
- We did not verify the 50-subtransaction and 100-subtransaction benchmark results.
- We did not check the claimed quadratic MultiXact work.
- Section “Development ideas”: we checked 1 of 9 checkable claims.
- Section “Monitoring”: our checked-claim count (2) exceeds our extracted total (1); the count needs review.
- We could not decide whether readers can obtain the benchmark environment.
- We could not decide whether the published benchmark details are complete.
- We could not decide who measured the benchmark.
- We hold no source mapping for “postgres-ai/postgresql-consulting”, so we did not check the article's claims about its code.
- We hold no source mapping for “postgres-ai/docs”, so we did not check the article's claims about its code.

## Notes

- B — the findings address the article's main subject. What we did not check is listed below. The findings directly check XID consumption, cache overflow, MultiXact expansion, standby visibility, and monitoring recommendations.
- We did not check everything in this article. What we did not check is listed below, in the words we recorded at the time. None of it moved the letter. We never charge our own limits to the article.
- Average of 5 axes: 3.26 · benchmark not reproducible, one step off (source not linked) · result B
- Some explanatory text is not shown in this edition; the grade and findings are complete.
- Some checks did not happen for this edition, and each one we know of is listed above.
- Checked against: github.com/postgres/postgres REL_12_8 at commit de835071fda945fb5e40340d3ea8dd2ca13e725c (pinned target); github.com/postgrespro/pg_wait_sampling v1.1.3 at commit b984f33528a479243884b8e23bac1240d4566bcc (pinned target); github.com/patroni/patroni v2.1.1 at commit 93efa91bbdc5a50cad4f99c4e99286340ab94ce8 (pinned target); https://about.gitlab.com/blog/2021/09/29/why-we-spent-the-last-month-eliminating-postgresql-subtransactions/ (fetched 2026-10-19T06:39:14.442084Z); https://blog.sentry.io/transaction-id-wraparound-in-postgres/ (fetched 2026-10-19T06:39:51.808214Z); https://docs.djangoproject.com/en/3.2/topics/db/transactions/ (fetched 2026-10-19T06:39:24.815590Z); https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/transaction/SavepointManager.html (fetched 2026-10-19T06:39:29.892841Z); https://en.wikipedia.org/wiki/Nested_transaction (fetched 2026-10-19T06:39:15.408422Z); https://fluca1978.github.io/2020/02/05/PLPGSQLExceptions.html (fetched 2026-10-19T06:39:37.602652Z); https://github.com/postgres/postgres/blob/78ab944cd4b9977732becd9d0bc83223b88af9a2/src/include/storage/proc.h (fetched 2026-10-19T06:39:56.184642Z); https://github.com/postgres/postgres/commit/573a71a5da70d6e2503c8f53e3b4f26b3b6d738d (fetched 2026-10-19T06:39:18.418943Z); https://gitlab.com/postgres-ai/postgresql-consulting/tests-and-benchmarks/-/issues/20 (fetched 2026-10-19T06:39:59.483479Z); https://gorm.io/docs/transactions.html (fetched 2026-10-19T06:39:33.952210Z); https://hasura.io/docs/latest/schema/postgres/default-values/sql-functions/ (fetched 2026-10-19T06:39:49.905984Z); https://mailchimp.com/what-we-learned-from-the-recent-mandrill-outage/ (fetched 2026-10-19T06:39:52.623406Z); https://news.ycombinator.com/item?id=28374333 (fetched 2026-10-19T06:39:12.920855Z); https://www.cybertec-postgresql.com/en/subtransactions-and-performance-in-postgresql/ (fetched 2026-10-19T06:39:57.788606Z); https://www.postgresql.org/docs/current/ddl-system-columns.html (fetched 2026-10-19T06:39:50.991436Z); https://www.postgresql.org/docs/current/plpython-subtransaction.html (fetched 2026-10-19T06:39:39.151370Z); https://www.postgresql.org/docs/current/sql-release-savepoint.html (fetched 2026-10-19T06:39:22.297060Z); https://www.postgresql.org/docs/current/sql-rollback-to.html (fetched 2026-10-19T06:39:21.256403Z); https://www.postgresql.org/docs/current/sql-savepoint.html (fetched 2026-10-19T06:39:20.192667Z); https://www.yiiframework.com/doc/guide/2.0/en/db-dao (fetched 2026-10-19T06:39:33.267482Z).
- Article captured 2026-10-19T06:39:00.357424Z · SHA-256 51133994bcabbe02b88a7e80c8a992d85df3d81cb6cef790f18a7a3fc61bcac5 · Text extracted from the article's HTML.
- Policy SHA-256 26c4b8ce941ee45080060aa6d04dec6af05f9efdff74d292af023066edcc1934 · Grading rules SHA-256 6fb334e79d6b9e7ed81d3238cc10d9de602ff87ed65ff2fa781f53bac5798765.
- gate: proceeded with reason codes HIGH_INJECTION
- We did not reproduce throughput, latency, wait-event counts, CPU profiles, or operating-system cache measurements.
- We did not read the article's embedded demonstrations and performance charts.
- We did not check every benchmark command, monitoring extension, proposed patch, or version introduction.
- We checked PostgreSQL 12.8 source. We did not check every mechanism against PostgreSQL 14beta3.
- We did not verify Aurora's implementation, its mitigation recommendations, the AWS quotations, or the Prime Day account.
- We did not check the claimed quadratic MultiXact work or determine which proposed SLRU changes shipped after 2021.
- We could not reach the SQL standard text or the cited SQLAlchemy, Active Record, and jOOQ documentation.
- The article gives August 31, 2021 without a time. We list that date at midnight UTC.
- article target version: bound to the most-cited major; also named 15 (1×), 14beta3 (1×), 13 (1×)
- source: postgres 12 was read at REL_12_8, its newest release when the article was published
- source: the article names no pg_wait_sampling release, so it was read at v1.1.3, the latest release when it was published
- source: the article names no patroni release, so it was read at v2.1.1, the latest release when it was published
- source: we did not check the article's claims about 2 linked GitLab projects against their source code, because we keep no copy of them
- 4 fetched pages are not listed above, because our policy does not allow linking them.
- review: the findings were written by one model and reviewed independently by a different model.
- 2026-10-29: Regraded under the current grading rules: the letter is the average of the axis letters, with every cap stated under it.
- 4 passages in this edition fell short of our own plain-English rules.
- Built from the article text captured above, 3 pinned source trees, and 20 fetched pages.
- 18 survived · 5 weakened · 0 withdrawn.

## Revision history

- [Revision 1](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c?v=43) · 2026-09-10 03:15 UTC · B · audit version not recorded · regrade version not recorded
  Article as first submitted. 16 accurate · 1 wrong · 2 caveats.
  ElephantSeal: B.
  Changes: First audit. Open: F20 “…TPS went down ~20x during 5 minutes…” (false); F6 “The xmin values in tuples have XID belonging to subtransactions, so each time we read such tuple…” (mostly accurate); F21 “…1000 writing transactions per second, but if they all use 10 subtransactions…” (mostly accurate).
- [Revision 2](https://pgtrue.postgres.ai/shared/brief/d44845a1-484a-4f98-9401-6eb9d4594e1c?v=49) · this page · 2026-10-19 06:39 UTC · B · audited with v1.0.14 (approx.) · regraded with v1.1.1 (approx.)
  Article text changed. 20 accurate · 1 wrong · 0 caveats.
  ElephantSeal: B. Open: the benchmark cannot yet be rerun from what is published.
  Changes: No longer reported: “…TPS went down ~20x during 5 minutes…”; “The xmin values in tuples have XID belonging to subtransactions, so each time we read such tuple…”; “…1000 writing transactions per second, but if they all use 10 subtransactions…”. New: F1 “RELEASE SAVEPOINT does not prevent the 64-XID cache overflow” (misleading).

Updated your article? Request a correction. A new edition appears at this address.