deadlock avoidance

Поиск
Список
Период
Сортировка
От Clarence Gardner
Тема deadlock avoidance
Дата
Msg-id Pine.SUN.4.02.10609252353500.11969-100000@beach.silcom.com
обсуждение исходный текст
Ответы Re: deadlock avoidance  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
I noticed the following in some of our code today:
    select ... <join list> ... for update of a, b;

Inasmuch as the cardinal rule for avoiding deadlocks is to acquire
locks in a consistent order, should such a construction be avoided
in favor of two separate "select ... for update" statements so that
the order of acquisition of a and b is known? I'm assuming that
there is no ordering implied/guaranteed by "for update of a, b".

Or am I missing something?

Clarence


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

Предыдущее
От: Michael Glaesemann
Дата:
Сообщение: Re: getting dates in the past
Следующее
От: Tom Lane
Дата:
Сообщение: Re: deadlock avoidance