From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Naga Appani <nagnrik(at)gmail(dot)com> |
Cc: | Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>, Kirill Reshke <reshkekirill(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [Proposal] Expose internal MultiXact member count function for efficient monitoring |
Date: | 2025-08-19 06:32:19 |
Message-ID: | aKQac2ZrY4UWBORR@paquier.xyz |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Aug 18, 2025 at 08:32:39PM -0500, Naga Appani wrote:
> Thanks a lot for taking the time to review this patch and share your thoughts.
>
> Here’s a short summary of what has changed in v5:
> - Added the new pg_get_multixact_stats() function in multixactfuncs.c.
> - Fixed the misleading “atomic read” comment in the accessor.
> - Clarified documentation: thresholds are described in terms of
> counts, since that’s what the code uses.
> - Added a members_bytes column in pg_get_multixact_stats() to give
> users a rough size estimate (num_members * 5), while making it clear
> this is layout-dependent.
>
> Please see my in-line replies below.
FWIW, I think that you should be a bit more careful before sending
updated patch sets. You have missed an extra point I have raised
upthread about the refactoring pieces: the switch from
ReadMultiXactCounts() to GetMultiXactInfo() can be done in a patch of
its own.
So I have extracted this part from your latest patch, and applied it
independently of the SQL function business. Now we are in an
advantageous position on HEAD: even if we do not conclude about the
SQL function to show the mxact numbers and offsets, we have the
function that gives an access to the data you are looking for. In
short, it is now possible to provide an equivalent of the feature you
want outside of core. Not saying that the patch cannot be useful, but
such refactoring pieces open more possibilities, and offer a cleaner
commit history with less churn in the main patches.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Smith | 2025-08-19 06:36:07 | Re: [WIP]Vertical Clustered Index (columnar store extension) - take2 |
Previous Message | Andrei Lepikhov | 2025-08-19 06:29:43 | Re: Plan caching and serialization for reuse across executions |