From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Joe Conway <mail(at)joeconway(dot)com> |
Cc: | Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com>, Gurjeet Singh <gurjeet(at)singh(dot)im>, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: RFC: pg_stat_logmsg |
Date: | 2024-07-18 04:32:48 |
Message-ID: | Zpia8GwTB9turihT@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jul 17, 2024 at 07:43:13AM -0400, Joe Conway wrote:
> On 7/16/24 18:14, Tomas Vondra wrote:
>> As for the feature, I've never done a fleet-wide analysis, so if this is
>> one of the main use cases, I'm not really sure I can judge if this is a
>> good tool for that. It seems like it might be a convenient way to do
>> that, but does that require we add the module to contrib?
>
> I had an offlist chat with Andres about this IIRC and he suggested he
> thought it ought to be just built in to the backend as part of the
> statistics subsystem. Lately though I have been toying with the idea of
> keeping it as an extension and basing it off Michael Paquier's work for
> Pluggable cumulative statistics.
This may live better as a contrib/ module, serving as well as an extra
template for what can be done with the pluggable stats. Adding that
in core is of course OK for me if that's the consensus. The APIs for
pluggable stats are really the same as what you would store in core,
minus the system functions you'd want to add in the catalog .dat
files, of course.
I'd like to get it this part done by the end of this commit fest to
have room with pg_stat_statements for this release, but well, we'll
see. As far as I can see everybody who commented on the thread seems
kind of OK with the idea to fix the stats kinds IDs in time, like
custom RMGRs. That's just simpler implementation-wise, but I'm also
looking for more opinions.
> Hmm, yeah, I had been planning to include postgres version as part of the
> output, but maybe it would need to be part of the key.
Seems to me that you should do both, then: add PG_VERSION to the
entries, and hash the keys with it for uniqueness. You could also
have a reset function that performs a removal of the stats for
anything else than the current PG_VERSION, for example.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Thomas Munro | 2024-07-18 04:40:07 | Re: CI, macports, darwin version problems |
Previous Message | shveta malik | 2024-07-18 04:27:17 | Re: Allow logical failover slots to wait on synchronous replication |