Re: walsender performance regression due to logical decoding on standby changes
Jeff Davis <pgsql@j-davis.com>
From: Jeff Davis <pgsql@j-davis.com>
To: Andres Freund <andres@anarazel.de>, pgsql-hackers@postgresql.org,
"Drouvot, Bertrand" <bertranddrouvot.pg@gmail.com>, Amit Kapila
<amit.kapila16@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>, Masahiko Sawada
<sawada.mshk@gmail.com>
Date: 2023-05-09T20:38:24Z
Lists: pgsql-hackers
On Tue, 2023-05-09 at 12:02 -0700, Andres Freund wrote: > I don't think the approach of not having any sort of "registry" of > whether > anybody is waiting for the replay position to be updated is > feasible. Iterating over all walsenders slots is just too expensive - Would it work to use a shared counter for the waiters (or, two counters, one for physical and one for logical), and just early exit if the count is zero? Regards, Jeff Davis
Commits
-
Optimize walsender wake up logic using condition variables
- bc971f4025c3 16.0 landed
-
For cascading replication, wake physical and logical walsenders separately
- e101dfac3a53 16.0 cited