Add pgstat_drop_matching_entries() to pgstats
Michael Paquier <michael@paquier.xyz>
Add pgstat_drop_matching_entries() to pgstats This allows users of the cumulative statistics to drop entries in the shared hash stats table, deleting as well local references. Callers of this function can optionally define a callback able to filter which entries to drop, similarly to pgstat_reset_matching_entries() with its callback do_reset(). pgstat_drop_all_entries() is refactored so as it uses this new function. Author: Lukas Fitti Discussion: https://postgr.es/m/CAP53PkwuFbo3NkwZgxwNRMjMfqPEqidD-SggaoQ4ijotBVLJAA@mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/utils/activity/pgstat_shmem.c | modified | +30 −1 |
| src/include/utils/pgstat_internal.h | modified | +2 −0 |
Discussion
- [PATCH] Optionally record Plan IDs to track plan changes for a query 45 messages · 2025-01-02 → 2026-03-19