Skip site navigation (1) Skip section navigation (2)

Re: pgsql/src backend/tcop/postgres.c include/misc ...

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql/src backend/tcop/postgres.c include/misc ...
Date: 2002-01-08 00:08:51
Message-ID: 15234.1010448531@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-committers
Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp> writes:
> As far as I see, the introduction of the ImmediateInterruptOK
> flag made HOLD/RESUME_INTERRUPTS scheme pretty meaningless.

Not at all.  The point of HOLD_INTERRUPTS is to disable any
CHECK_FOR_INTERRUPTS call that might be issued by subroutines
you call. That's very different from ImmediateInterruptOK, which
can be set true only in *extremely* limited areas wherein we can
fully understand the behavior of executing the cancel/die request
in the signal handler.

> Does 'die' interrupts still really need HOLD/RESUME_INTERRUPTS
> scheme ? If 'die' interrupts are only for normal shutdown,
> even LockWaitCancel() isn't needed.

It's needed for cancels.  Possibly we could skip it during shutdown,
but trying to do that seems risky and pointless.  (If we skip it
then we are leaving the lock-manager shared memory in a bad state,
which is exactly what die() should not do.)

			regards, tom lane

In response to

Responses

pgsql-committers by date

Next:From: Hiroshi InoueDate: 2002-01-08 00:58:24
Subject: Re: pgsql/src backend/tcop/postgres.c include/misc ...
Previous:From: Hiroshi InoueDate: 2002-01-07 23:46:29
Subject: Re: pgsql/src backend/tcop/postgres.c include/misc ...

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group