Re: Autogenerate some wait events code and documentation - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Autogenerate some wait events code and documentation
Date
Msg-id ZKeZVPEBkBxYs1FY@paquier.xyz
Whole thread Raw
In response to Re: Autogenerate some wait events code and documentation  (Andres Freund <andres@anarazel.de>)
Responses Re: Autogenerate some wait events code and documentation
List pgsql-hackers
On Thu, Jul 06, 2023 at 06:19:43PM -0700, Andres Freund wrote:
> On 2023-07-06 09:36:12 +0900, Michael Paquier wrote:
>> So you mean renaming the existing events like WalSenderWaitForWAL to
>> WalSenderWaitForWal?
>
> Yes.
>
>> The impact on existing monitoring queries is not zero because any changes
>> would be silent, and that's the part that worried me the most even if it can
>> remove one column in the txt file.
>
> Then let's just use - or so to indicate the inferred name, with a "string"
> overriding it?

Hmm.  If we go down this road I would make the choice of simplicity
and remove entirely a column, then, generating the snakecase from the
camelcase or vice-versa (say like a $string =~ s/([a-z]+)/$1_/g;),
even if it means having slightly incompatible strings showing to the
users. And I'd rather minimize the number of exceptions we need to
handle in this automation (aka no exception rules for some keywords
like "SSL" or "WAL", etc.).
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Isaac Morland
Date:
Subject: Re: Fix search_path for all maintenance commands
Next
From: Dilip Kumar
Date:
Subject: Re: Disabling Heap-Only Tuples