public inbox for [email protected]  
help / color / mirror / Atom feed
From: Shinoda, Noriyoshi (PSD Japan FSI) <[email protected]>
To: Michael Paquier <[email protected]>
To: Naga Appani <[email protected]>
Cc: Ashutosh Bapat <[email protected]>
Cc: Tomas Vondra <[email protected]>
Cc: Xuneng Zhou <[email protected]>
Cc: torikoshia <[email protected]>
Cc: Kirill Reshke <[email protected]>
Cc: [email protected] <[email protected]>
Subject: RE: [Proposal] Expose internal MultiXact member count function for efficient monitoring
Date: Mon, 13 Apr 2026 01:28:55 +0000
Message-ID: <LV8PR84MB3787CF6E56DCC99AE23E712EEE242@LV8PR84MB3787.NAMPRD84.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <[email protected]>
References: <CA+QeY+CF2q2M51k5t4rZZ2SNeEq8ORf3Dr8T1+jm72VsHRJfjw@mail.gmail.com>
	<CAExHW5shToKbeiw1eRGeiSyVeCYZUJyw2KUtBKYFn0J3dCGzbA@mail.gmail.com>
	<CA+QeY+CqRjUj93_kV0YmMBqfkgo4WGEoiYOaP_wCMoJ8FOKpog@mail.gmail.com>
	<[email protected]>
	<CAExHW5t-di9g+S-7pdXxCA8z3AtCWYn_=Ou9fY0aMg7K0wA2KA@mail.gmail.com>
	<CA+QeY+DO2y-3JfK68Wqerv2wmG43B7aoAhsWa7YrsKZo_ayOtg@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<CA+QeY+Bjbe8GuNYaDDHMAYJMoR9F+R7xLKWsUTjJrcxfzs_cZA@mail.gmail.com>
	<[email protected]>

Hi, thanks to the developers and reviewers.

It seems the data type of "num_mxids", which is the result of the "pg_get_multixact_stats" function, does not match the documentation. 
In pg_proc.dat, the data type is int8.
[pg_proc.dat]
+  proname => 'pg_get_multixact_stats', provolatile => 'v',
+  proallargtypes => '{int8,int8,int8,xid}', proargmodes => '{o,o,o,o}',

However, the documentation specifies it as an "integer".
[func-info.sgml]
+        ( <parameter>num_mxids</parameter> <type>integer</type>,
+          <parameter>num_members</parameter> <type>bigint</type>,

There may be debate about whether uint32 should be called integer or bigint, but I think it's better if the implementation and documentation are consistent. The small attached patch changes the data type of the num_mxids column in the documentation to "bigint" to match the implementation.

Regards,
Noriyoshi Shinoda

-----Original Message-----
From: Michael Paquier <[email protected]> 
Sent: Tuesday, December 30, 2025 4:44 PM
To: Naga Appani <[email protected]>
Cc: Ashutosh Bapat <[email protected]>; Tomas Vondra <[email protected]>; Xuneng Zhou <[email protected]>; torikoshia <[email protected]>; Kirill Reshke <[email protected]>; [email protected]
Subject: Re: [Proposal] Expose internal MultiXact member count function for efficient monitoring

On Mon, Dec 29, 2025 at 08:57:11PM -0600, Naga Appani wrote:
> The oldest_multixact correctly advances to reflect the cleanup.
> 
> Thanks for adding the pg_read_all_stats privilege check!
> 
> I think this is ready for RFC.

Thanks for looking.  I have done an extra round of brush-up, then applied the set.  The buildfarm looks OK with it.
--
Michael


Attachments:

  [application/octet-stream] pg_get_multixact_stats_doc_v1.diff (731B, 2-pg_get_multixact_stats_doc_v1.diff)
  download | inline diff:
diff --git a/doc/src/sgml/func/func-info.sgml b/doc/src/sgml/func/func-info.sgml
index 80cf11083d6..f3e147c2d7d 100644
--- a/doc/src/sgml/func/func-info.sgml
+++ b/doc/src/sgml/func/func-info.sgml
@@ -3013,7 +3013,7 @@ acl      | {postgres=arwdDxtm/postgres,foo=r/postgres}
         </indexterm>
         <function>pg_get_multixact_stats</function> ()
         <returnvalue>record</returnvalue>
-        ( <parameter>num_mxids</parameter> <type>integer</type>,
+        ( <parameter>num_mxids</parameter> <type>bigint</type>,
           <parameter>num_members</parameter> <type>bigint</type>,
           <parameter>members_size</parameter> <type>bigint</type>,
           <parameter>oldest_multixact</parameter> <type>xid</type> )


view thread (42+ messages)

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: RE: [Proposal] Expose internal MultiXact member count function for efficient monitoring
  In-Reply-To: <LV8PR84MB3787CF6E56DCC99AE23E712EEE242@LV8PR84MB3787.NAMPRD84.PROD.OUTLOOK.COM>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox