Re: Change pg_cancel_*() to ignore current backend

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>
Cc: Eric Ridge <e_ridge(at)tcdi(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Change pg_cancel_*() to ignore current backend
Date: 2015-05-22 21:51:03
Message-ID: 13917.1432331463@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com> writes:
> On 5/22/15 3:08 PM, Eric Ridge wrote:
>> Rather than change the behavior of pg_cancel/terminate_backend(), why not change pg_stat_activity to exclude the current session? Seems like showing a row in pg_stat_activity for "SELECT * FROM pg_stat_activity" is kinda useless anyways.

> Interesting idea. I suspect that would be even more invasive than
> modifying the functions though...

-1 ... some other columns in pg_stat_activity are potentially useful even
for the current session, eg session and transaction start times.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2015-05-22 21:54:35 Re: jsonb concatenate operator's semantics seem questionable
Previous Message Josh Berkus 2015-05-22 21:30:18 Asynchronous DRAM Self-Refresh