Re: Add pg_stat_kind_info system view

Sami Imseih <samimseih@gmail.com>

From: Sami Imseih <samimseih@gmail.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>, Tristan Partin <tristan@partin.io>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2026-07-02T00:26:23Z
Lists: pgsql-hackers
> > But also, because this will be used to calculate consumption, we
> > should add a note in
> > the documentation to differentiate between live storage usage vs the
> > DSA footprint,
> > which will not be shrunk when entries are deleted. Someone may be confused
> > that their entries are much lower after deleting entries, but their memory
> > footprint is still high because the OS does not reclaim the free'd space.
> > What do you think?
>
> Hmm.  I am not completely sure which way is best here.  So, I think
> that I am just going to drop this field for now (entry_size as of
> latest patch), and keep the rest of the patch.  It's still useful to
> me, and we could always add one or more memory-related field later as
> we feel in this release cycle.

Right. I also think this needs more discussion, and it should not hold
up everything else.

--
Sami



Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Add system view pg_stat_kind_info

  2. Introduce pluggable APIs for Cumulative Statistics