Re: postgresql locks the whole table! - Mailing list pgsql-general

From Greg Stark
Subject Re: postgresql locks the whole table!
Date
Msg-id 878ylo1nlj.fsf@stark.dyndns.tv
Whole thread Raw
In response to Re: postgresql locks the whole table!  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: postgresql locks the whole table!  (Mike Mascari <mascarm@mascari.com>)
Re: postgresql locks the whole table!  (Stephan Szabo <sszabo@megazone.bigpanda.com>)
List pgsql-general
It's not strictly necessary to have a list of all xids at all. The normal
"shared read lock" is just "take the write lock, increment the readers
counter, unlock" Anyone who wants to write has to wait (using, eg, a condition
variable) until the readers count goes to 0.

This gets the right semantics but without the debugging info of a list of
lockers. Other than debugging the only advantage I see to having the list of
lockers is for deadlock detection. Is that absolutely mandatory?

--
greg

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: CREATE RULE problem/question requesting workaround
Next
From: Mike Mascari
Date:
Subject: Re: postgresql locks the whole table!