Re: Report bytes and transactions actually sent downtream

From: Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com>
To: Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>
Cc: shveta malik <shveta(dot)malik(at)gmail(dot)com>, Ashutosh Sharma <ashu(dot)coek88(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Report bytes and transactions actually sent downtream
Date: 2025-10-03 13:47:34
Message-ID: aN/T9s1S4lHoVaef@ip-10-97-1-34.eu-west-3.compute.internal
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On Fri, Oct 03, 2025 at 12:22:05PM +0530, Ashutosh Bapat wrote:
> Here's patchset addressing two issues:

Thanks for the patch update!

> I
> have added a note in documentation for plugin authors, warning them
> that this isn't expected.

What note are you referring to? (I'm failing to see it).

> I don't think it's worth adding complexity
> in code to support such a case unless we see a practical need for the
> same.

Sounds good.

> Issue 2: Once X + 2 is loaded, further statistics are accumulated on
> the top of statistics accumulated by version X. Attached patch fixes
> issue 2 by zero'ing out the stats when the plugin does not report the
> statistics.

+#define REPLSLOT_SET_TO_ZERO(fld) statent->fld = 0

It looks like that the associated "undef" is missing.

Regards,

--
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Previous Message Greg Burd 2025-10-03 13:29:09 Re: Fixing a few minor misusages of bms_union()