From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Tom Lane <tgl(at)svr1(dot)postgresql(dot)org> |
Cc: | pgsql-committers(at)postgresql(dot)org |
Subject: | Re: pgsql-server/src backend/access/heap/heapam.c ... |
Date: | 2003-09-23 21:00:15 |
Message-ID: | 200309232100.h8NL0Fv13742@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Tom Lane wrote:
> Fix LISTEN/NOTIFY race condition reported by Gavin Sherry. While a
> really general fix might be difficult, I believe the only case where
> AtCommit_Notify could see an uncommitted tuple is where the other guy
> has just unlistened and not yet committed. The best solution seems to
> be to just skip updating that tuple, on the assumption that the other
> guy does not want to hear about the notification anyway. This is not
> perfect --- if the other guy rolls back his unlisten instead of committing,
> then he really should have gotten this notify. But to do that, we'd have
> to wait to see if he commits or not, or make UNLISTEN hold exclusive lock
> on pg_listener until commit. Either of these answers is deadlock-prone,
> not to mention horrible for interactive performance. Do it this way
> for now. (What happened to that project to do LISTEN/NOTIFY in memory
> with no table, anyway?)
Added to TODO:
* Allow LISTEN/NOTIFY to store info in memory rather than tables
--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2003-09-23 21:00:18 | pgsql-server/doc TODO |
Previous Message | Bruce Momjian | 2003-09-23 20:45:58 | pgsql-server/doc TODO |