Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitda7540b

Browse files
committed
Change ANALYZE to take ShareUpdateExclusiveLock not AccessShareLock on
the table being analyzed. This prevents two ANALYZEs from runningconcurrently on the same table and possibly suffering concurrent-updatefailures while trying to store their results into pg_statistic. Thedownside is that a database-wide ANALYZE executed within a transactionblock will hold ShareUpdateExclusiveLock on many tables simultaneously,which could lead to concurrency issues or even deadlock against anothersuch ANALYZE. However, this seems a corner case of less importancethan getting unexpected errors from a foreground ANALYZE when autovacuumelects to analyze the same table concurrently. Per discussion.
1 parent2e5e856 commitda7540b

File tree

2 files changed

+201
-202
lines changed

2 files changed

+201
-202
lines changed

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp