Re: REFRESH MATERIALIZED VIEW locklevel - Mailing list pgsql-hackers

From Kevin Grittner
Subject Re: REFRESH MATERIALIZED VIEW locklevel
Date
Msg-id 1362678939.69291.YahooMailNeo@web162904.mail.bf1.yahoo.com
Whole thread Raw
In response to REFRESH MATERIALIZED VIEW locklevel  (Andres Freund <andres@2ndquadrant.com>)
Responses Re: REFRESH MATERIALIZED VIEW locklevel  (Andres Freund <andres@2ndquadrant.com>)
Re: REFRESH MATERIALIZED VIEW locklevel  ("anarazel@anarazel.de" <andres@anarazel.de>)
List pgsql-hackers
Andres Freund <andres@2ndquadrant.com> wrote:

> if I understand things correctly REFRESH MATERIALIZED VIEW locks
> the materialized view with an AcessExclusiveLock even if the view
> already contains data.

Yeah.  At the time I had to make a decision on that, REINDEX
CONCURRENTLY did not seem reliable with a weaker lock, and REFRESH
MATERIALIZED VIEW has to rebuild indexes (among other things).  If
we have all the issues sorted out with REINDEX CONCURRENTLY then
the same techniques will probably apply to RMV without too much
difficulty.  It's a bit late to think about that for 9.3, though.

> I am pretty sure that will - understandably - confuse users, so I
> vote for at least including a note about that in the docs.

Will see about working that in.

-Kevin

--
Kevin Grittner
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Kevin Grittner
Date:
Subject: Re: odd behavior in materialized view
Next
From: Andres Freund
Date:
Subject: Re: REFRESH MATERIALIZED VIEW locklevel