Re: ALTER TABLE .. SET SCHEMA lock strength

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: ALTER TABLE .. SET SCHEMA lock strength
Date: 2011-01-01 17:17:53
Message-ID: 1293902273.1892.60835.camel@ebony
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, 2011-01-01 at 11:06 -0500, Robert Haas wrote:

> While reviewing the SQL/MED patch, I happened to notice that
> ExecAlterObjectSchemaStmt calls AlterTableNamespace with a lock mode
> argument of AccessExclusiveLock. Does anyone see a reason why
> ShareUpdateExclusiveLock would be insufficient?

It seemed unsafe to me to do that while an object was being accessed,
since it effectively changes the search_path, which is dangerous.

Seems like a good change, if it really is viable.

--
Simon Riggs http://www.2ndQuadrant.com/books/
PostgreSQL Development, 24x7 Support, Training and Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2011-01-01 17:29:20 Re: Sync Rep Design
Previous Message Stefan Kaltenbrunner 2011-01-01 17:13:24 Re: Sync Rep Design