Re: Testing LISTEN/NOTIFY more effectively

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Testing LISTEN/NOTIFY more effectively
Date: 2019-07-28 01:08:50
Message-ID: 25695.1564276130@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund <andres(at)anarazel(dot)de> writes:
> I wonder if there aren't similar dangers around the notify handling. In
> your patch we don't print them particularly eagerly. Doesn't that also
> open us up to timing concerns?

I think probably not, because of the backend-side restrictions on when
notify messages will be sent. The corresponding case for the NOTICE
bug we just fixed would be if a backend sent a NOTIFY before blocking;
but it can't do that internally to a transaction, and anyway the proposed
test script isn't doing anything that tricky.

I did spend some time thinking about how isolationtester might report
notifys that are sent spontaneously (without any "triggering" query)
but I didn't feel that that was worth messing with. We'd have to
have the program checking all the connections not just the one that's
running what it thinks is the currently active step.

We might be approaching a time where it's worth scrapping the
isolationtester logic and starting over. I'm not volunteering though.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2019-07-28 01:33:45 Re: pg_upgrade fails with non-standard ACL
Previous Message Andres Freund 2019-07-28 00:54:18 Re: Testing LISTEN/NOTIFY more effectively