Re: auxiliary processes in pg_stat_ssl

Alvaro Herrera <alvherre@2ndquadrant.com>

From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Stephen Frost <sfrost@snowman.net>
Cc: Robert Haas <robertmhaas@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Kuntal Ghosh <kuntalghosh.2007@gmail.com>
Date: 2019-11-12T21:50:08Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. pg_stat_activity: document client_port being null

  2. pg_stat_{ssl,gssapi}: Show only processes with connections

On 2019-Nov-04, Stephen Frost wrote:

> Based on what we claim in our docs, it does look like 'client_port IS
> NOT NULL' should work.  I do think we might want to update the docs to
> make it a bit more explicit, what we say now is:
> 
> TCP port number that the client is using for communication with this
> backend, or -1 if a Unix socket is used
> 
> We don't explain there that NULL means the backend doesn't have an
> external connection even though plenty of those entries show up in every
> instance of PG.  Perhaps we should add this:
> 
> If this field is null, it indicates that this is an internal process
> such as autovacuum.
> 
> Which is what we say for 'client_addr'.

Seems sensible.  Done.  Thanks

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services