Re: ThreadAbortException fails to get thrown from thread making remoting call.
- From: Goran Sliskovic <gsliskov@xxxxxxxxx>
- Date: Thu, 15 Mar 2007 00:51:01 +0100
Howard Swope wrote:
Thanks for your response.......
The way that I have gotten around this is just making the calls from an AsyncDelegate and waiting for the return. This way the call is going out on a threadpool thread and the thread that I want to abort is waiting for it to return and it will throw the ThreadAbortException (I do cleanup in my finally block).
Haven't tried that method, just make sure you don't starve the thread pool. There could be some limit on number of threads allocated to thread pool.
The problem I run into with remoting is that in case of connection physically going down, remote call would hang forever in same cases (timing issue, waiting for response from remote host). That call is blocked in native windows api (recv on socket) and there is no way of stopping it. Eventually I guess TCP keepalive timer would kick in and tear down connection, but I've never waited that long to check. Anyway, it's rare condition, so few "hanging" threads don't impact much.
Why do you have to abort?
Regards,
Goran
.
- References:
- ThreadAbortException fails to get thrown from thread making remoting call.
- From: Howard Swope
- Re: ThreadAbortException fails to get thrown from thread making remoting call.
- From: Goran Sliskovic
- Re: ThreadAbortException fails to get thrown from thread making remoting call.
- From: Howard Swope
- ThreadAbortException fails to get thrown from thread making remoting call.
- Prev by Date: Re: ThreadAbortException fails to get thrown from thread making remoting call.
- Next by Date: TypeFilterLevel.Full and TypeFilterLevel.Low for channels in the same AppDomain
- Previous by thread: Re: ThreadAbortException fails to get thrown from thread making remoting call.
- Next by thread: TypeFilterLevel.Full and TypeFilterLevel.Low for channels in the same AppDomain
- Index(es):
Relevant Pages
|