Re: pgstat: Flush some statistics within running transactions, take 2

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Sami Imseih <samimseih(dot)pg(at)gmail(dot)com>
Cc: Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com>, Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, Lukas Fittl <lukas(at)fittl(dot)com>
Subject: Re: pgstat: Flush some statistics within running transactions, take 2
Date: 2026-12-02 00:28:43
Message-ID: aw9mO_4IZdPSrL4_@paquier.xyz
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Dec 01, 2026 at 04:10:57PM -0600, Sami Imseih wrote:
> I removed these. Looking back in the thread, you did mention that
> "sometimes we keep around a few objects for the sake of pg_upgrade, so
> I would recommend to just leave that be."

Yes, sometimes we do. I tend to put an effort in documenting this
fact in the tests, so as one does not remove them. Less relations
also mean less CPU cycles pg_upgrade has to deal with, so perhaps
dropping these relations would not impact the coverage. I'm fine with
letting them be, there is enough to deal with these days..

> pgstat_relation_flush_cb() and pgstat_index_flush_cb(), and reverts some
> unrelated comment rewording v22 had in test_custom_var_stats.c. I also
> made a few other small comment adjustments while going through it.
>
> I ran check-world incrementally for each patch, and all pass.
>
> WDYT?

I think that it has become easier to review as a whole.
--
Michael

In response to

Browse pgsql-hackers by date

  From Date Subject
Previous Message Sami Imseih 2026-12-02 00:16:09 Re: Fix relation statistics around transactional TRUNCATE