Documentation improvements for pg_locks with respect to SSI.
Explain that querying pg_locks does not simultaneously lock both the normal lock manager and the predicate lock manager. Per discussion with Kevin Grittner.
This commit is contained in:
parent
194e6ee74b
commit
eb03cff820
@ -7085,13 +7085,18 @@
|
|||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
When the <structname>pg_locks</structname> view is accessed, the
|
The <structname>pg_locks</structname> view displays data from both the
|
||||||
internal lock manager data structures are momentarily locked, and
|
regular lock manager and the predicate lock manager, which are
|
||||||
a copy is made for the view to display. This ensures that the
|
separate systems. When this view is accessed, the internal data
|
||||||
view produces a consistent set of results, while not blocking
|
structures of each lock manager are momentarily locked, and copies are
|
||||||
normal lock manager operations longer than necessary. Nonetheless
|
made for the view to display. Each lock manager will therefore
|
||||||
there could be some impact on database performance if this view is
|
produce a consistent set of results, but as we do not lock both lock
|
||||||
frequently accessed.
|
managers simultaneously, it is possible for locks to be taken or
|
||||||
|
released after we interrogate the regular lock manager and before we
|
||||||
|
interrogate the predicate lock manager. Each lock manager is only
|
||||||
|
locked for the minimum possible time so as to reduce the performance
|
||||||
|
impact of querying this view, but there could nevertheless be some
|
||||||
|
impact on database performance if it is frequently accessed.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user