Re: BUG #3790: pg_restore error canceling statement due to user request

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, Gregory Stark <stark(at)enterprisedb(dot)com>, "Mike C(dot)" <smith(dot)not(dot)western(at)gmail(dot)com>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #3790: pg_restore error canceling statement due to user request
Date: 2007-12-04 21:35:22
Message-ID: 20071204213522.GA22875@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Bruce Momjian escribió:
> Alvaro Herrera wrote:

> Ah, OK. Right now we have these two cancel messages:
>
> if (cancel_from_timeout)
> ereport(ERROR,
> (errcode(ERRCODE_QUERY_CANCELED),
> errmsg("canceling statement due to statement timeout")));
> else
> ereport(ERROR,
> (errcode(ERRCODE_QUERY_CANCELED),
> errmsg("canceling statement due to user request")));
>
> While the first one is fine, the second one is used for Control-C and
> the new autovacuum code to exit an activity when it is blocking someone
> from getting a table lock. Perhaps we just need to change the wording
> to "canceling statement" and not specify the cause.

We can distinguish the cases -- there's no need to mix them in a single
message. See the patch I attached somewhere else in this thread.

--
Alvaro Herrera http://www.advogato.org/person/alvherre
"No hay hombre que no aspire a la plenitud, es decir,
la suma de experiencias de que un hombre es capaz"

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Martin Pitt 2007-12-04 22:43:40 Re: Test suite fails on alpha architecture
Previous Message Bruce Momjian 2007-12-04 20:54:52 Re: BUG #3790: pg_restore error canceling statement due to user request