mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Add a 'waiting' column to pg_stat_activity to carry the same information
that ps_status provides by appending 'waiting' to the PS display. This completes the project of making it feasible to turn off process title updates and instead rely on pg_stat_activity. Per my suggestion a few weeks ago.
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
<!-- $PostgreSQL: pgsql/doc/src/sgml/monitoring.sgml,v 1.36 2006/06/29 20:00:08 tgl Exp $ -->
|
||||
<!-- $PostgreSQL: pgsql/doc/src/sgml/monitoring.sgml,v 1.37 2006/08/19 01:36:23 tgl Exp $ -->
|
||||
|
||||
<chapter id="monitoring">
|
||||
<title>Monitoring Database Activity</title>
|
||||
@ -245,7 +245,8 @@ postgres: <replaceable>user</> <replaceable>database</> <replaceable>host</> <re
|
||||
<row>
|
||||
<entry><structname>pg_stat_activity</></entry>
|
||||
<entry>One row per server process, showing database OID, database name,
|
||||
process <acronym>ID</>, user OID, user name, current query, time at
|
||||
process <acronym>ID</>, user OID, user name, current query, query's
|
||||
waiting status, time at
|
||||
which the current query began execution, time at which the process
|
||||
was started, and client's address and port number. The columns
|
||||
that report data on the current query are available unless the
|
||||
@ -649,6 +650,17 @@ postgres: <replaceable>user</> <replaceable>database</> <replaceable>host</> <re
|
||||
</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><literal><function>pg_stat_get_backend_waiting</function>(<type>integer</type>)</literal></entry>
|
||||
<entry><type>boolean</type></entry>
|
||||
<entry>
|
||||
True if the given server process is waiting for a lock,
|
||||
but only if the current user is a superuser or the same user as that of
|
||||
the session being queried (and
|
||||
<varname>stats_command_string</varname> is on)
|
||||
</entry>
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<entry><literal><function>pg_stat_get_backend_activity_start</function>(<type>integer</type>)</literal></entry>
|
||||
<entry><type>timestamp with time zone</type></entry>
|
||||
|
Reference in New Issue
Block a user