Re: RFC: replace pg_stat_activity.waiting with something more descriptive

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Merlin Moncure <mmoncure(at)gmail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: RFC: replace pg_stat_activity.waiting with something more descriptive
Date: 2015-06-25 14:01:39
Message-ID: 25332.1435240899@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund <andres(at)anarazel(dot)de> writes:
> On 2015-06-25 16:26:39 +0530, Amit Kapila wrote:
>> Won't leaving former contents as it is (until the next thing is being
>> blocked) could give misleading information. Currently we mark 'waiting'
>> as false as soon as Heavy Weight Lock is over, so following that way
>> sounds more appropriate, is there any reason why you want it differently
>> than what we are doing currently?

> But we don't do the same for query, so I don't think that says much. I
> think it'd be useful because it gives you a bit more chance to see what
> you blocked on last, even if the time the backend was blocked was very
> short.

The problem with the query analogy is that it's possible to tell whether
the query is active or not, by looking at the status column. We need to
avoid a situation where you can't tell if the wait status is current or
merely the last thing waited for.

At the moment I'm inclined to think we should put this on the back burner
until we see what Ilya submits. None of the proposals for changing
pg_stat_activity sound terribly clean to me.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2015-06-25 14:15:00 Re: RFC: replace pg_stat_activity.waiting with something more descriptive
Previous Message Tatsuo Ishii 2015-06-25 13:51:48 Re: pgbench - allow backslash-continuations in custom scripts