Re: pgsql-server: Rearrange pg_subtrans handling as

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: pgsql-server: Rearrange pg_subtrans handling as
Дата
Msg-id 20040824034153.GF27308@dcc.uchile.cl
обсуждение исходный текст
Ответ на Re: [COMMITTERS] pgsql-server: Rearrange pg_subtrans handling as  (Christopher Kings-Lynne <chriskl@familyhealth.com.au>)
Список pgsql-hackers
On Tue, Aug 24, 2004 at 09:17:59AM +0800, Christopher Kings-Lynne wrote:
> Just random speculation, but could we use a pg_subtrans-like setup to do 
> row share locks?
> 
> ie. Store them in a sort of table to avoid the problems with limited 
> shared memory size?

Hmm ... how would you map the row number to an array index?  I think it
could work if you answer the above question.  The problem is doing it
for any possible table/row combination, and make it so that in a given
moment only a small space in the array is used.  (If you don't do that,
there will be a lot of thrashing.)

What's needed is a four-dimension integer array:

pg_database    oid
pg_class    oid    BlockNumber    OffsetNumber

The value would keep how many share-lockers there are.

-- 
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"Cómo ponemos nuestros dedos en la arcilla del otro. Eso es la amistad; jugar
al alfarero y ver qué formas se pueden sacar del otro" (C. Halloway en
La Feria de las Tinieblas, R. Bradbury)



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [COMMITTERS] pgsql-server: Rearrange pg_subtrans handling as
Следующее
От: Tom Lane
Дата:
Сообщение: Re: auto-casting a bit more intelligent in 8.0 ... ?