mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Add deadlock counter to pg_stat_database
Adds a counter that tracks number of deadlocks that occurred in each database to pg_stat_database. Magnus Hagander, reviewed by Jaime Casanova
This commit is contained in:
@ -283,8 +283,8 @@ postgres: <replaceable>user</> <replaceable>database</> <replaceable>host</> <re
|
||||
read requests avoided by finding the block already in buffer cache),
|
||||
number of rows returned, fetched, inserted, updated and deleted, the
|
||||
total number of queries canceled due to conflict with recovery (on
|
||||
standby servers), number and size of temporary files used, and time
|
||||
of last statistics reset.
|
||||
standby servers), number and size of temporary files used, total
|
||||
number of deadlocks detected, and time of last statistics reset.
|
||||
</entry>
|
||||
</row>
|
||||
|
||||
@ -909,6 +909,14 @@ postgres: <replaceable>user</> <replaceable>database</> <replaceable>host</> <re
|
||||
</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><literal><function>pg_stat_get_db_deadlocks</function>(<type>oid</type>)</literal></entry>
|
||||
<entry><type>bigint</type></entry>
|
||||
<entry>
|
||||
Number of deadlocks detected in the database
|
||||
</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><literal><function>pg_stat_get_numscans</function>(<type>oid</type>)</literal></entry>
|
||||
<entry><type>bigint</type></entry>
|
||||
|
Reference in New Issue
Block a user