]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Add information about "generation" when dropping twice pgstats entry
authorMichael Paquier <michael@paquier.xyz>
Fri, 8 Aug 2025 00:07:54 +0000 (09:07 +0900)
committerMichael Paquier <michael@paquier.xyz>
Fri, 8 Aug 2025 00:07:54 +0000 (09:07 +0900)
commitf770006928d0a697e0fe0463cdb3e052b86ef940
tree9c6f0af0411ca9a4fab0400d218cc5d37c2ab0cc
parent06f44481646a669b43a19a2c501a164459d194f1
Add information about "generation" when dropping twice pgstats entry

Dropping twice a pgstats entry should not happen, and the error report
generated was missing the "generation" counter (tracking when an entry
is reused) that has been added in 818119afccd3.

Like d92573adcb02, backpatch down to v15 where this information is
useful to have, to gather more information from instances where the
problem shows up.  A report has shown that this error path has been
reached on a standby based on 17.3, for a relation stats entry and an
OID close to wraparound.

Author: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Discussion: https://postgr.es/m/CAN4RuQvYth942J2+FcLmJKgdpq6fE5eqyFvb_PuskxF2eL=Wzg@mail.gmail.com
Backpatch-through: 15
src/backend/utils/activity/pgstat_shmem.c