Re: the s_lock_stuck on perform_spin_delay

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: the s_lock_stuck on perform_spin_delay
Дата
Msg-id CA+TgmoZeNF8AaiQncuacdo3kAMz-pdSrVe1Ev-CcW=Ld7fYM0Q@mail.gmail.com
обсуждение исходный текст
Ответ на Re: the s_lock_stuck on perform_spin_delay  (Matthias van de Meent <boekewurm+postgres@gmail.com>)
Ответы Re: the s_lock_stuck on perform_spin_delay
Список pgsql-hackers
Thanks for jumping in with a review, Matthias!

On Wed, Jan 10, 2024 at 8:03 AM Matthias van de Meent
<boekewurm+postgres@gmail.com> wrote:
> I'm not 100% sure on the policy of this, but theoretically you could
> use LockAquireExtended(dontWait=true) while holding a spin lock, as
> that would not have an unknown duration. Then again, this function
> also does elog/ereport, which would cause issues, still, so this code
> may be the better option.

This is definitely not allowable, and anybody who is thinking about
doing it should replace the spinlock with an LWLock.

--
Robert Haas
EDB: http://www.enterprisedb.com



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

Предыдущее
От: Andrei Lepikhov
Дата:
Сообщение: Re: Custom explain options
Следующее
От: Robert Haas
Дата:
Сообщение: Re: Relation bulk write facility