Server-side intercepting of client connection disconnect?


(Alexandru Nedelcu) #1

Hi all,

I’m wondering if it’s possible to intercept and act on early client disconnects.

For example, say that the request triggers a slow task that can take seconds, but the client closes the connection before it is complete. Is there any way to detect that and act on it?

Thanks,


(Rich Dougherty) #2

I don’t know of a way to do this, but it would be great if there was. I’ve long wished for a way to get a callback when a request ends, so that you can close resources (e.g. delete temporary files) when a request is served or closed.