On Fri, Jun 12, 2026 at 06:21:42PM -0500, Sami Imseih wrote:
> I have implemented an approach, which I will share in the next
> revision, where every stats kind is written to its own dedicated
> dshash rather than into the common one. This is a new
> configuration in PgStat_KindInfo where an extension (or even a
> core stats kind) can request to be placed in a dedicated hash,
> else in the common hash.
> 
> I like this better, especially for kinds with unique access
> patterns like pg_stat_statements, where the view function and
> eviction need to iterate over all their own entries frequently.
> A dedicated hash eliminates the full-scan problem without a
> secondary coordination dshash.

I'm finding this alternative quite appealing, indeed.  For PGSS, I was
wondering about how it would be possible to avoid a secondary hash,
and I did not consider an approach where we could bypass the main one.
--
Michael

Attachment: signature.asc
Description: PGP signature

Reply via email to