On Mon, Nov 20, 2023 at 05:43:17PM +0300, Nazir Bilal Yavuz wrote: > Yes, the timings for the writes and the syncs should work. Another > question I have in mind is the pg_stat_reset_shared() function. When > we call it with 'io' it will reset pg_stat_wal's timings and when we > call it with 'wal' it won't reset them, right?
pg_stat_reset_shared() with a target is IMO a very edge case, so I'm OK with the approach of resetting timings in pg_stat_wal even if 'io' was implied because pg_stat_wal would feed partially from pg_stat_io. I'd take that as a side-cost in favor of compatibility while making the stats gathering cheaper overall. I'm OK as well if people counter-argue on this point, though that would mean to keep entirely separate views with duplicated fields that serve the same purpose, impacting all deployments because it would make the stats gathering heavier for all. -- Michael
signature.asc
Description: PGP signature