Re: reindex creates predicate lock on index root - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: reindex creates predicate lock on index root
Date
Msg-id 4DEF1372.3020603@enterprisedb.com
Whole thread Raw
In response to Re: reindex creates predicate lock on index root  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
List pgsql-hackers
On 08.06.2011 06:37, Kevin Grittner wrote:
> You're right; that one was a false alarm.  While REINDEX was reading
> the heap to build the index it got an SIREAD lock on a *heap* page.

We never take locks on heap pages directly, so it must've been a 
promotion from heap tuple locks.

> While that could arguably be avoided, even though the heap is being
> read in a serializable transaction, I'm not inclined to get really
> excited about it.  If someone wants to dodge it, they can always run
> the REINDEX in READ COMMITTED or REPEATABLE READ mode.  Maybe 9.2
> material if there's nothing to do that matters more than that.

That should be pretty easy to avoid, though. I think we should fix it now.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


pgsql-hackers by date:

Previous
From: Merlin Moncure
Date:
Subject: Re: WALInsertLock contention
Next
From: Florian Pflug
Date:
Subject: Re: [PATCH] Bug in XPATH() if expression returns a scalar value