pgpool: Doc: fix track_table_mutation memory figures and eviction descr

From: Tatsuo Ishii <ishii(at)postgresql(dot)org>
To: pgpool-committers(at)lists(dot)postgresql(dot)org
Subject: pgpool: Doc: fix track_table_mutation memory figures and eviction descr
Date: 2026-09-30 02:20:28
Message-ID: E1xBjvo-0000000DvYZ-2p0S@gothos.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgpool-committers

Doc: fix track_table_mutation memory figures and eviction description.

The track table mutation documentation understated the shared memory the
feature requires and described its eviction order incorrectly.

TrackTableMutationEntry is 56 bytes, not the documented 40: it holds two
struct timeval fields (16 bytes each on LP64), two ints, a uint32, an int
and a bool, which pad to 56. With the default track_table_mutation_table_size
of 2048 that is ~112 KB for the entries, plus ~4 KB for the default 1024
hash buckets, so the feature needs ~116 KB rather than ~80 KB. The
4096-table example needs ~228 KB, not ~160 KB. The bucket array was not
accounted for at all before; it is now mentioned explicitly.

The docs also stated that the oldest entries are evicted when the map is
full. table_map_insert() actually scans from bucket zero and evicts the
head of the first non-empty bucket, so the eviction order follows the hash
bucket layout and not the write time. Describe what the code does, and
note that expired entries are reclaimed opportunistically, so a live entry
is only evicted when more than track_table_mutation_table_size tables are
written inside one TTL window.

The Japanese document patch by Tatsuo Ishii.

Author: Nadav Shatz <nadav(at)tailorbrands(dot)com>
Reviewed-by: Tatsuo Ishii <ishii(at)postgresql(dot)org>
Discussion: https://www.postgresql.org/message-id/CACeKOO1v6%2BKiK-qns_37zCz7YYxJ6Zi_xKaLAuQcjkYQcjQu2Q%40mail.gmail.com
Backpatch-through: master only

Branch
------
master

Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=17352edb15faf64752a22fd4f1491cf3f268cd19

Modified Files
--------------
doc.ja/src/sgml/loadbalance.sgml | 17 ++++++++++-------
doc/src/sgml/loadbalance.sgml | 23 +++++++++++++++--------
2 files changed, 25 insertions(+), 15 deletions(-)

Browse pgpool-committers by date

  From Date Subject
Next Message Tatsuo Ishii 2026-10-01 11:16:27 pgpool: Fix lifecheck buffer overrun.
Previous Message Tatsuo Ishii 2026-09-29 10:57:21 pgpool: Reject negative read length in pool_read2.