Why release index relation lock

Поиск
Список
Период
Сортировка
От DT
Тема Why release index relation lock
Дата
Msg-id BAY173-W528399A71D28B3547E7CCCE6F40@phx.gbl
обсуждение исходный текст
Ответы Re: Why release index relation lock  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Why release index relation lock  (sivananda reddy <nanda.opdba@gmail.com>)
Список pgsql-general
Hi,

  For some operations, such as INSERT/UPDATE, heap relation lock is held until
xact commit, but index relation lock is released after command end. Some other
operations also hold index relation lock until xact commit, such as VACUUM.

  I have read chapter 54. Index Access Method Interface Definition in documentation,
and README in nbtree, but still can not figure out:
1. What's the rule of index relation locking?
2. Releasing lock is for higher concurrency, but for INSERT/UPDATE, i did not find
   any operation that could get benefit from releasing index relation lock? Or to
   say : what will happen if we treat index relation lock like heap relation lock?

Thanks.

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

Предыдущее
От: David Johnston
Дата:
Сообщение: Excellent article on SQL
Следующее
От: Frank Church
Дата:
Сообщение: How can I run a PostgreSQL database outside /var/run/postgresql?