Re: Removing the pgstat_flush_io() call from the walwriter - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Removing the pgstat_flush_io() call from the walwriter
Date
Msg-id k4mfoecuatqj33kcsm2jp4kfawuiy3jmzqf3ahlffcjfeyteii@2diiruepoqj4
Whole thread Raw
Responses Re: Removing the pgstat_flush_io() call from the walwriter
List pgsql-hackers
Hi,

On 2024-12-18 15:14:07 +0000, Bertrand Drouvot wrote:
> While working on [1], it has been noticed that pgstat_flush_io() is called for
> the walwriter. Indeed, it's coming from the pgstat_report_wal() call in
> WalWriterMain(). That can not report any I/O stats activity (as the
> walwriter is not part of the I/O stats tracking, see pgstat_tracks_io_bktype()).
> 
> The behavior is there since 28e626bde00 and I did not find any explicit reason
> to do so provided in the linked thread [2].
> 
> Calling pgstat_flush_io() from there looks unnecessary, so $SUBJECT, until the
> walwriter is part of the I/O stats tracking system.

I don't really see the point of this change? What do we gain by moving stuff
around like you did?

Greetings,

Andres Freund



pgsql-hackers by date:

Previous
From: Daniel Gustafsson
Date:
Subject: Re: Test to dump and restore objects left behind by regression
Next
From: Bertrand Drouvot
Date:
Subject: Re: Removing the pgstat_flush_io() call from the walwriter