Re: BUG #8290: broken/unexpected locking behavior

Поиск
Список
Период
Сортировка
От Jamey Poirier
Тема Re: BUG #8290: broken/unexpected locking behavior
Дата
Msg-id FA8A9A935BFD3A4D8F0CDA1C4F611BCC0C8642B7F2@IT-1874.Isys.com
обсуждение исходный текст
Ответ на Re: BUG #8290: broken/unexpected locking behavior  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Ответы Re: BUG #8290: broken/unexpected locking behavior  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Список pgsql-bugs
Thank you Alvaro.  Yes, this explains it.
It doesn't help to fix it but at least I know now that it's a known "featur=
e".
I'll have to see about coming up with a work-around as we likely won't get =
to 9.3 anytime soon.

Thank you!

-----Original Message-----
From: pgsql-bugs-owner@postgresql.org [mailto:pgsql-bugs-owner@postgresql.o=
rg] On Behalf Of Alvaro Herrera
Sent: Tuesday, July 09, 2013 2:59 PM
To: pgnube@gmail.com
Cc: pgsql-bugs@postgresql.org
Subject: Re: [BUGS] BUG #8290: broken/unexpected locking behavior

pgnube@gmail.com escribi=F3:

> I sent the following information to pgsql-general to ask if it is=20
> expected locking behavior.  The only responses that I got said that=20
> the behavior is reproducible on 9.1 and 9.3 beta 2.
> Nobody said that this is expected locking behavior and I believe it to=20
> be a bug, so I am filing this bug report.
> The exact steps on how to reproduce the problem are shown below. =20
> Thank you for putting together a great DB and for working on this bug rep=
ort.

See here:
http://www.commandprompt.com/blogs/alvaro_herrera/2010/11/fixing_foreign_ke=
y_deadlocks/

There are further posts on the same topic in that blog.  The patch dealing =
with it was finally committed for the 9.3 version, due to be released later=
 this year:
http://git.postgresql.org/gitweb/?p=3Dpostgresql.git;a=3Dcommitdiff;h=3D0ac=
5ad5134f2769ccbaefec73844f8504c4d6182
At the bottom of the commit messages there are some message-ids on (rather =
long) discussions about that patch.  You can search for them at http://www.=
postgresql.org/list/ (just enter the msgid in the box and click search).

If you try a 9.3 snapshot, you should be able to replace the FOR UPDATE in =
your queries with FOR NO KEY UPDATE and there should be no deadlock.
Even if it does not, I hope the aforementioned posts explain what is going =
on.

--=20
=C1lvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services


--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make change=
s to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: BUG #8290: broken/unexpected locking behavior
Следующее
От: Tom Lane
Дата:
Сообщение: Re: BUG #8289: pg_stat_statements incorrect query text when executing multiple queries in a single PQexec