Re: Proposal: Out-of-Order NOTIFY via GUC to Improve LISTEN/NOTIFY Throughput

From: "Joel Jacobson" <joel(at)compiler(dot)org>
To: "Rishu Bagga" <rishu(dot)postgres(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, "nik(at)postgres(dot)ai" <nik(at)postgres(dot)ai>
Subject: Re: Proposal: Out-of-Order NOTIFY via GUC to Improve LISTEN/NOTIFY Throughput
Date: 2025-07-18 15:51:47
Message-ID: 21f74513-85b0-4bd1-a6b6-09a6d3902e97@app.fastmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jul 18, 2025, at 10:15, Joel Jacobson wrote:
> On Fri, Jul 18, 2025, at 02:49, Rishu Bagga wrote:
>> Hi all,
>>
>> There’s been some renewed attention on improving the performance of the
>> LISTEN/NOTIFY system, which historically hasn’t scaled well under high
>> notify frequency. Joel Jacobson recently shared some work on optimizing
>> the LISTEN path [1], and I wanted to follow up with a proposal focused on
>> the NOTIFY side.
>
> To clarify, my patch optimizes parallelizability of NOTIFY, without
> degrading parallelizability of LISTEN/UNLISTEN.

I realize my above clarification is not technically true,
what I meant to say is:

My patch improves NOTIFY TPS when many backends are listening on multiple
channels by eliminating unnecessary syscall wake‑ups, but it doesn't increase
the internal parallelism of the NOTIFY queue itself.

/Joel

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jehan-Guillaume de Rorthais 2025-07-18 15:53:14 [(known) BUG] DELETE/UPDATE more than one row in partitioned foreign table
Previous Message Andres Freund 2025-07-18 15:43:47 Re: Adding wait events statistics