pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
To: shveta malik <shveta.malik@gmail.com>
Cc: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
Cc: Ashutosh Sharma <ashu.coek88@gmail.com>
Cc: Amit Kapila <amit.kapila16@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Report bytes and transactions actually sent downtream
Date: Wed, 24 Sep 2025 06:42:04 +0000
Message-ID: <aNOSvFWplHTeHGd2@ip-10-97-1-34.eu-west-3.compute.internal> (raw)
In-Reply-To: <CAJpy0uDKj383GF8SyUbxz4C1i1783B_0s1=bvB3D1fMxkeu6Aw@mail.gmail.com>
References: <CAA4eK1Kdf=F8y8VK2zY_Pq6QA4nJcXzOHs1fAmK2YGFdVYHGwQ@mail.gmail.com>
	<CAExHW5tfVHABuv1moL_shp7oPrWmg8ha7T8CqwZxiMrKror7iw@mail.gmail.com>
	<aK8LlVEAKLGsIytg@ip-10-97-1-34.eu-west-3.compute.internal>
	<CAJpy0uAxw_BKOTAtbnPdBcBCMS6jqLiaCraqLjwhRvuytb008A@mail.gmail.com>
	<CAExHW5uKnETTnspzqFpGgTjzWNpHSxctWZ4OuuauA0hO9BNTOw@mail.gmail.com>
	<CAJpy0uAONZOJrnAive+1PNCHRFOcojLxVL0NW-RYm6okqn45+A@mail.gmail.com>
	<CAExHW5vnRPp5dof35DEGdc8W2tS16E5CbmGey28Y=RJ9QrpfAQ@mail.gmail.com>
	<CAE9k0Pmgnab8ASstv5VBHXkZFqfS-r=QQi6V7fabv6n2_5Hbzg@mail.gmail.com>
	<CAExHW5sak5HQUGLQJ2ODVnQT4syFWXykgnksZX8Qi7Uu5jfqMg@mail.gmail.com>
	<CAJpy0uDKj383GF8SyUbxz4C1i1783B_0s1=bvB3D1fMxkeu6Aw@mail.gmail.com>

Hi,

On Wed, Sep 24, 2025 at 11:38:30AM +0530, shveta malik wrote:
> On Wed, Sep 24, 2025 at 11:08 AM Ashutosh Bapat
> <ashutosh.bapat.oss@gmail.com> wrote:
> >
> > In WalSndWriteData() we can't rely on what happens in a low level API
> > like socket_putmessage(). And we are counting the number of bytes in
> > the logically decoded message. So, I actually wonder whether we should
> > count 1 byte of 'd' in sentBytes. Shveta, Bertand, what do you think?
> >
> 
> If we are not counting all such metadata bytes ((or can't reliably do
> so), then IMO, we shall skip counting msgtype as well.

Agree. Maybe mention in the doc that metadata (including msgtype) bytes are not
taken into account?

Regards,

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





view thread (123+ messages)  latest in thread

Message-ID: <aNOSvFWplHTeHGd2@ip-10-97-1-34.eu-west-3.compute.internal>
Permalink:  ../aNOSvFWplHTeHGd2@ip-10-97-1-34.eu-west-3.compute.internal/
Also on:    postgresql.org/message-id/aNOSvFWplHTeHGd2@ip-10-97-1-34.eu-west-3.compute.internal

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: bertranddrouvot.pg@gmail.com, shveta.malik@gmail.com, ashutosh.bapat.oss@gmail.com, ashu.coek88@gmail.com, amit.kapila16@gmail.com
  Subject: Re: Report bytes and transactions actually sent downtream
  In-Reply-To: <aNOSvFWplHTeHGd2@ip-10-97-1-34.eu-west-3.compute.internal>
  References: <CAA4eK1Kdf=F8y8VK2zY_Pq6QA4nJcXzOHs1fAmK2YGFdVYHGwQ@mail.gmail.com> <CAExHW5tfVHABuv1moL_shp7oPrWmg8ha7T8CqwZxiMrKror7iw@mail.gmail.com> <aK8LlVEAKLGsIytg@ip-10-97-1-34.eu-west-3.compute.internal> <CAJpy0uAxw_BKOTAtbnPdBcBCMS6jqLiaCraqLjwhRvuytb008A@mail.gmail.com> <CAExHW5uKnETTnspzqFpGgTjzWNpHSxctWZ4OuuauA0hO9BNTOw@mail.gmail.com> <CAJpy0uAONZOJrnAive+1PNCHRFOcojLxVL0NW-RYm6okqn45+A@mail.gmail.com> <CAExHW5vnRPp5dof35DEGdc8W2tS16E5CbmGey28Y=RJ9QrpfAQ@mail.gmail.com> <CAE9k0Pmgnab8ASstv5VBHXkZFqfS-r=QQi6V7fabv6n2_5Hbzg@mail.gmail.com> <CAExHW5sak5HQUGLQJ2ODVnQT4syFWXykgnksZX8Qi7Uu5jfqMg@mail.gmail.com> <CAJpy0uDKj383GF8SyUbxz4C1i1783B_0s1=bvB3D1fMxkeu6Aw@mail.gmail.com> <aNOSvFWplHTeHGd2@ip-10-97-1-34.eu-west-3.compute.internal>

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

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