Re: Clients disconnect but query still runs - Mailing list pgsql-general

From Greg Stark
Subject Re: Clients disconnect but query still runs
Date
Msg-id 407d949e0907290656w1f25e4a4u163b11a891fc14d@mail.gmail.com
Whole thread Raw
In response to Re: Clients disconnect but query still runs  (Jasen Betts <jasen@xnet.co.nz>)
Responses Re: Clients disconnect but query still runs
Re: Clients disconnect but query still runs
Re: Clients disconnect but query still runs
List pgsql-general
On Wed, Jul 29, 2009 at 1:58 PM, Jasen Betts<jasen@xnet.co.nz> wrote:
> can't coerce a signal from the network stack? the linux socket(2)
> manpage is full of promise (SIGPIPE, SIGURG, SIGIO)

[please don't quote the entire message back, just the part you're responding to]

Well SIGPIPE is no help since it would only fire if we tried to write
to the socket anyways.

SIGIO on the other hand looks like exactly what we would need. I'm not
sure if it can be set to fire a signal only when the connection is
disconnected and not for other state changes but if so it would be
interesting.

SIGURG might be useful but it would be more complex to use and less
widely useful since it would only work if the client disconnects
gracefully (though it might be worth checking into as an alternative
to our existing query cancel method).

--
greg
http://mit.edu/~gsstark/resume.pdf

pgsql-general by date:

Previous
From: Sam Mason
Date:
Subject: Re: comparing NEW and OLD (any good this way?)
Next
From: Sam Mason
Date:
Subject: Re: Clients disconnect but query still runs