| От | Tom Lane |
|---|---|
| Тема | Re: userlock changes for 8.1/8.2 |
| Дата | |
| Msg-id | 3558.1106667538@sss.pgh.pa.us обсуждение |
| Ответ на | Re: userlock changes for 8.1/8.2 ("Merlin Moncure" <merlin.moncure@rcsonline.com>) |
| Список | pgsql-hackers |
"Merlin Moncure" <merlin.moncure@rcsonline.com> writes:
> However, it would be nice to have system generated unique tuple
> identifier. There isn't one currently that would fit in the userlock
> restriction of 48 bits.
Sure there is: the ctid of a row in an agreed-on table works fine.
The reason it's system-wide unique is that user_locks.c forcibly
includes your database OID in the lock tag.
It would be reasonable to allow user control of the lock's relId field
and maybe even dbId field, but that just takes an expansion of the API
for user_locks.c. There's no need to put overhead on the rest of
Postgres for this.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера