Re: LISTEN/NOTIFY race condition?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Laurent Birtz <laurent(dot)birtz(at)kryptiva(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: LISTEN/NOTIFY race condition?
Date: 2008-03-05 01:53:14
Message-ID: 3683.1204681994@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Laurent Birtz <laurent(dot)birtz(at)kryptiva(dot)com> writes:
> From the observed sequence of events, it would appear that the event
> thread inserts a tuple in the pg_listener table BEFORE the command thread
> actually commits the transaction. However, when this transaction commits,
> Postgres does not actually find the event thread's tuple in this table.

I'm wondering exactly when you commit the LISTEN? The command thread
can't see the pg_listener tuple until it's committed ...

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message jfkunos 2008-03-05 02:21:22 Tom Belich
Previous Message Jasen Betts 2008-03-05 00:32:54 BUG #4011: spelling mistake in comments