public inbox for [email protected]  
help / color / mirror / Atom feed
From: Yogesh Sharma <[email protected]>
To: Bertrand Drouvot <[email protected]>
Cc: [email protected]
Subject: Re: Add a write_to_file member to PgStat_KindInfo
Date: Thu, 21 Nov 2024 12:57:18 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <Zz4YrnuKw/[email protected]>
References: <[email protected]>
	<CAN55FZ0k3jLe5vExkqw3Lrn5bWqdaU61Rqd8vUeQs=ZzO=CgZw@mail.gmail.com>
	<Zz4YrnuKw/[email protected]>

Hi,

Thanks for patch. I have tested both patches and they work as per design.

My +1 for v1, it is much cleaner approach and has properly named 
functions whereas in v2 it is not.

Injection points is documented, if so, doc patch is missing.

Regards,
Yogesh

On 11/20/24 12:13, Bertrand Drouvot wrote:
> Hi,
>
> On Wed, Nov 20, 2024 at 05:45:55PM +0300, Nazir Bilal Yavuz wrote:
>> I think this is a good idea. +1 for the $SUBJECT.
> Thanks for looking at it!
>
>> There are duplicated codes in the injection_stats_fixed.c file. Do you
>> think that 'modifying existing functions to take an argument to
>> differentiate whether the kind is default or no-write' would be
>> better?
> Some of the new functions are callbacks so we don't have the control on the
> parameters list that the core is expecting.
>
> It remains:
>
> pgstat_register_inj_fixed_no_write()
> pgstat_report_inj_fixed_no_write()
> injection_points_stats_fixed_no_write()
>
> for which I think we could add an extra "write_to_file" argument on their original
> counterparts.
>
> Not sure how many code reduction we would get, so out of curiosity I did the
> exercice in v2 attached and that gives us:
>
> v1:
> 8 files changed, 211 insertions(+), 2 deletions(-)
>
> v2:
> 8 files changed, 152 insertions(+), 22 deletions(-)
>
> I don't have a strong opinion for this particular case here (I think the code
> is harder to read but yeah there is some code reduction): so I'm fine with
> v2 too.
>
> Regards,
>






view thread (10+ messages)  latest in thread

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]
  Subject: Re: Add a write_to_file member to PgStat_KindInfo
  In-Reply-To: <[email protected]>

* 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