Re: NOTIFY command impact

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Cc: Rob Brucks <rob(dot)brucks(at)rackspace(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: NOTIFY command impact
Date: 2017-02-21 21:38:47
Message-ID: CAKFQuwb=tsEG9UT+pvhgmqYjSuvKTgkbFo+co2KsQ8t-qKaJQw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Feb 21, 2017 at 2:17 PM, Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
wrote:

> On 02/21/2017 01:07 PM, Rob Brucks wrote:
>
>>
>> Do you see any long-term problems with constantly issuing "NOTIFY"
>> commands every 30 seconds without an associated "LISTEN" command?
>>
>
> Depending on how long 'long term' is:
>
> https://www.postgresql.org/docs/9.6/static/sql-notify.html
>
> "There is a queue that holds notifications that have been sent but not yet
> processed by all listening sessions

​Its not clear in the OP that this is the case (it seems to be) but the
documentation is non-specific as to what happens when "# of listeners" = 0;
I suspect that said messages are created and then immediately discarded -
though apparently they do make it over to the standby server​ too - and
likely also immediately discarded there as well.

David J.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Patrick B 2017-02-21 21:44:04 bloat indexes - opinion
Previous Message John R Pierce 2017-02-21 21:30:24 Re: Wired-Protocol Specification?