Re: Error code returned by lock_timeout

Lists: pgsql-hackers
From: Boszormenyi Zoltan <zb(at)cybertec(dot)at>
To: PostgreSQL Developers <pgsql-hackers(at)postgresql(dot)org>
Cc: Hans-Jürgen Schönig <hs(at)cybertec(dot)at>
Subject: Error code returned by lock_timeout
Date: 2013-06-27 05:22:35
Message-ID: 51CBCC1B.9020702@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Hi,

I just realized that in the original incarnation of lock_timeout,
I used ERRCODE_LOCK_NOT_AVAILABLE (to be consistent with NOWAIT)
but the patch that was accepted into 9.3 contained ERRCODE_QUERY_CANCELED
which is the same as for statement_timeout.

Which would be more correct?

Thanks in advance,
Zoltán Böszörményi

--
----------------------------------
Zoltán Böszörményi
Cybertec Schönig & Schönig GmbH
Gröhrmühlgasse 26
A-2700 Wiener Neustadt, Austria
Web: http://www.postgresql-support.de
http://www.postgresql.at/


From: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
To: Boszormenyi Zoltan <zb(at)cybertec(dot)at>
Cc: PostgreSQL Developers <pgsql-hackers(at)postgresql(dot)org>, Hans-Jürgen Schönig <hs(at)cybertec(dot)at>
Subject: Re: Error code returned by lock_timeout
Date: 2013-06-27 15:03:53
Message-ID: CAHGQGwHAom4SyODQ_Orkdc_V_KU=GiOt0mh=3K_bpmNxdySHGg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Thu, Jun 27, 2013 at 2:22 PM, Boszormenyi Zoltan <zb(at)cybertec(dot)at> wrote:
> Hi,
>
> I just realized that in the original incarnation of lock_timeout,
> I used ERRCODE_LOCK_NOT_AVAILABLE (to be consistent with NOWAIT)
> but the patch that was accepted into 9.3 contained ERRCODE_QUERY_CANCELED
> which is the same as for statement_timeout.
>
> Which would be more correct?

ISTM that ERRCODE_LOCK_NOT_AVAILABLE is more suitable...

Regards,

--
Fujii Masao


From: Boszormenyi Zoltan <zb(at)cybertec(dot)at>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: PostgreSQL Developers <pgsql-hackers(at)postgresql(dot)org>, Hans-Jürgen Schönig <hs(at)cybertec(dot)at>
Subject: Re: Error code returned by lock_timeout
Date: 2013-06-27 15:12:04
Message-ID: 51CC5644.7050909@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

2013-06-27 17:03 keltezéssel, Fujii Masao írta:
> On Thu, Jun 27, 2013 at 2:22 PM, Boszormenyi Zoltan <zb(at)cybertec(dot)at> wrote:
>> Hi,
>>
>> I just realized that in the original incarnation of lock_timeout,
>> I used ERRCODE_LOCK_NOT_AVAILABLE (to be consistent with NOWAIT)
>> but the patch that was accepted into 9.3 contained ERRCODE_QUERY_CANCELED
>> which is the same as for statement_timeout.
>>
>> Which would be more correct?
> ISTM that ERRCODE_LOCK_NOT_AVAILABLE is more suitable...

I think, too. Can someone commit this one-liner to master and 9.3?

Best regards,
Zoltán Bsöszörményi

--
----------------------------------
Zoltán Böszörményi
Cybertec Schönig & Schönig GmbH
Gröhrmühlgasse 26
A-2700 Wiener Neustadt, Austria
Web: http://www.postgresql-support.de
http://www.postgresql.at/

Attachment Content-Type Size
lock_timeout-errcode-fix.patch text/x-patch 443 bytes