Re: reporting reason for certain locks

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: reporting reason for certain locks
Date: 2010-11-25 15:07:56
Message-ID: AANLkTimS45WUpZWacNrG7Gxe1YYsDEwq+sNAvvYVDiiM@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Nov 25, 2010 at 10:05 AM, Alvaro Herrera
<alvherre(at)commandprompt(dot)com> wrote:
> Excerpts from Robert Haas's message of jue nov 25 11:56:27 -0300 2010:
>
>> No, what I was suggesting was taking the existing function:
>>
>> extern void pgstat_report_waiting(bool waiting);
>>
>> ...and instead doing something like this:
>>
>> extern void pgstat_report_waiting(char *reason);
>>
>> ...and then arrange to pass the reason via the eponymous argument.
>
> Ah, I was looking for a SQL-callable function :-)  Hmm, maybe this would
> work.

I was just thinking it might be a good place for it because we're
already doing some nontrivial work at that point anyway. Although,
lock acquisition (especially of AccessShareLocks) is already a bit of
a hotspot, so we definitely have to be careful what we put in there no
matter how we do it.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2010-11-25 16:06:25 problem with Win32 buildfarm
Previous Message Robert Haas 2010-11-25 15:06:39 Re: Horizontal Write Scaling