Re: Listen / Notify - what to do when the queue is full

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Listen / Notify - what to do when the queue is full
Дата
Msg-id 23390.1263947059@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Listen / Notify - what to do when the queue is full  (Jeff Davis <pgsql@j-davis.com>)
Ответы Re: Listen / Notify - what to do when the queue is full  (Jeff Davis <pgsql@j-davis.com>)
Re: Listen / Notify - what to do when the queue is full  (Jeff Davis <pgsql@j-davis.com>)
Список pgsql-hackers
Jeff Davis <pgsql@j-davis.com> writes:
> I was also worried about holding multiple LWLocks at once -- is such
> practice generally avoided in the rest of the code?

It's allowed but remember that there is no deadlock detection in lwlock.c.
You must be very certain that there is only one possible order in which
such locks could be taken.  Interactions with heavyweight locks would be
bad news as well.

> It appears that the locks are only taken when LISTEN or NOTIFY is
> involved.

On the whole it might be better if a heavyweight lock were used,
such that it'll automatically clean up after commit.  (I'm still
wondering if we couldn't do without the lock altogether though.)
        regards, tom lane


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

Предыдущее
От: Jeff Davis
Дата:
Сообщение: Re: Listen / Notify - what to do when the queue is full
Следующее
От: Robert Haas
Дата:
Сообщение: Re: lock_timeout GUC patch