Re: [PATCH] lock_timeout and common SIGALRM framework

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Boszormenyi Zoltan <zb(at)cybertec(dot)at>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Marc Cousin <cousinmarc(at)gmail(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>, Hans-Juergen Schoenig <hs(at)cybertec(dot)at>, Ants Aasma <ants(at)cybertec(dot)at>, Robert Haas <robertmhaas(at)gmail(dot)com>
Subject: Re: [PATCH] lock_timeout and common SIGALRM framework
Date: 2012-07-13 22:23:31
Message-ID: 27465.1342218211@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Boszormenyi Zoltan <zb(at)cybertec(dot)at> writes:
>>> Try SET deadlock_timeout = 0;

Actually, when I try that I get

ERROR: 0 is outside the valid range for parameter "deadlock_timeout" (1 .. 2147483647)

So I don't see any bug here. The places that are unconditionally doing
"enable_timeout_after(..., DeadlockTimeout);" are perfectly fine. The
only place that might need an if-test has already got one:

if (StatementTimeout > 0)
! enable_timeout_after(STATEMENT_TIMEOUT, StatementTimeout);
else
! disable_timeout(STATEMENT_TIMEOUT, false);

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2012-07-13 22:25:26 Re: isolation check takes a long time
Previous Message Alvaro Herrera 2012-07-13 22:23:21 Re: [PATCH] lock_timeout and common SIGALRM framework