pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Robert Haas <rhaas@postgresql.org>
To: pgsql-committers@postgresql.org
Subject: pgsql: Extend framework from commit 53be0b1ad to report latch waits.
Date: Tue, 04 Oct 2016 15:02:22 +0000
Message-ID: <E1brREc-00084X-43@gemulon.postgresql.org> (raw)
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

Extend framework from commit 53be0b1ad to report latch waits.

WaitLatch, WaitLatchOrSocket, and WaitEventSetWait now taken an
additional wait_event_info parameter; legal values are defined in
pgstat.h.  This makes it possible to uniquely identify every point in
the core code where we are waiting for a latch; extensions can pass
WAIT_EXTENSION.

Because latches were the major wait primitive not previously covered
by this patch, it is now possible to see information in
pg_stat_activity on a large number of important wait events not
previously addressed, such as ClientRead, ClientWrite, and SyncRep.

Unfortunately, many of the wait events added by this patch will fail
to appear in pg_stat_activity because they're only used in background
processes which don't currently appear in pg_stat_activity.  We should
fix this either by creating a separate view for such information, or
else by deciding to include them in pg_stat_activity after all.

Michael Paquier and Robert Haas, reviewed by Alexander Korotkov and
Thomas Munro.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/6f3bd98ebfc008cbd676da777bb0b2376c4c4bfa

Modified Files
--------------
contrib/postgres_fdw/connection.c     |   3 +-
doc/src/sgml/monitoring.sgml          | 169 ++++++++++++++++++++++++
src/backend/access/transam/parallel.c |   4 +-
src/backend/access/transam/xlog.c     |   7 +-
src/backend/executor/nodeGather.c     |   3 +-
src/backend/libpq/be-secure-openssl.c |   4 +-
src/backend/libpq/be-secure.c         |   7 +-
src/backend/libpq/pqmq.c              |   4 +-
src/backend/postmaster/autovacuum.c   |   3 +-
src/backend/postmaster/bgworker.c     |   7 +-
src/backend/postmaster/bgwriter.c     |   5 +-
src/backend/postmaster/checkpointer.c |   3 +-
src/backend/postmaster/pgarch.c       |   3 +-
src/backend/postmaster/pgstat.c       | 236 ++++++++++++++++++++++++++++++++--
src/backend/postmaster/syslogger.c    |   4 +-
src/backend/postmaster/walwriter.c    |   3 +-
src/backend/replication/basebackup.c  |   3 +-
src/backend/replication/syncrep.c     |   4 +-
src/backend/replication/walreceiver.c |   7 +-
src/backend/replication/walsender.c   |   9 +-
src/backend/storage/buffer/bufmgr.c   |   7 +-
src/backend/storage/ipc/latch.c       |  18 ++-
src/backend/storage/ipc/shm_mq.c      |   7 +-
src/backend/storage/ipc/standby.c     |   5 +-
src/backend/storage/lmgr/lock.c       |   3 -
src/backend/storage/lmgr/lwlock.c     |   6 +-
src/backend/storage/lmgr/predicate.c  |   3 +-
src/backend/storage/lmgr/proc.c       |   8 +-
src/backend/utils/adt/misc.c          |   4 +-
src/include/pgstat.h                  |  99 ++++++++++++--
src/include/storage/latch.h           |   9 +-
src/include/storage/lwlock.h          |   2 +-
src/include/storage/proc.h            |   2 +-
src/test/modules/test_shm_mq/setup.c  |   3 +-
src/test/modules/test_shm_mq/test.c   |   3 +-
35 files changed, 584 insertions(+), 83 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


view thread (25+ messages)  latest in thread

Message-ID: <E1brREc-00084X-43@gemulon.postgresql.org>
Permalink:  ../E1brREc-00084X-43@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1brREc-00084X-43@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: rhaas@postgresql.org
  Subject: Re: pgsql: Extend framework from commit 53be0b1ad to report latch waits.
  In-Reply-To: <E1brREc-00084X-43@gemulon.postgresql.org>
  References: <E1brREc-00084X-43@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox