You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
To simplify interaction between collector process and client backendsrequesting profile or history data the current patch adds shared datastructures to store statistics: the fixed-size shared hash table to keepprofile and fixed-size shared array to implement ring buffer for historydata.Shared hash table for profile has fixed size specified by`pg_wait_sampling.max_profile_entries` GUC. The least used entries arediplaced from hash table when its overflow encounters. The evictionalgorithm is the same that is used in pg_stat_kcache extension - it'sbased on usage metric stored within hash table entries.The shared structures for profile and history are solely in-memory andnot persisted to external disk. So after server restart all statisticsfully reset. This is not bad because for wait monitoring it's enough tokeep track differential counters in profile statistics.Current patch also makes all timing period GUCs reloadable via SIGHUP.Other GUCs in some way have impact on allocation of shared resources sothey are done changable via server restart.The history keeping looks not usable for regular monitoring of waitevents so in current patch it's disabled by default by specifying zerovalue for `pg_wait_sampling.history_period` GUC.