Re: DDL Damage Assessment
От | Claudio Freire |
---|---|
Тема | Re: DDL Damage Assessment |
Дата | |
Msg-id | CAGTBQpZhTEFFN0TNFHrPoRgbMch-kBuCLz14-qQtmtE7pN51ZA@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: DDL Damage Assessment (Peter Geoghegan <pg@heroku.com>) |
Ответы |
Re: DDL Damage Assessment
|
Список | pgsql-hackers |
On Thu, Oct 2, 2014 at 5:37 PM, Peter Geoghegan <pg@heroku.com> wrote: > Session 3 is an innocent bystander. It goes to query the same table in > an ordinary, routine way - a SELECT statement. Even though session 2's > lock is not granted yet, session 3 is not at liberty to skip the queue > and get its own AccessShareLock. The effect is about the same as if > session 2 did need to hold an AccessExclusiveLock for ages: read > queries block for a long time. And yet, in theory session 2's impact > on production should not be minimal, if we consider something like > EXPLAIN output. The explain would show the AccessExclusiveLock, so it would be enough for a heads-up to kill all idle-in-transaction holding locks on the target relation (if killable, or just wait). Granted, it's something that's not easily automatable, whereas a nowait is. However, rather than nowait, I'd prefer "cancellable" semantics, that would cancel voluntarily if any other transaction requests a conflicting lock, like autovacuum does.
В списке pgsql-hackers по дате отправления: