Folks, no replies, but I think know the answer. A bit of lateral thinking
made me ask "why is the proxy staying alive for so long anyway?" A svcutil
generated class hides IDisposible behind Close and Abort methods. Implement
IDisposible in a partial class and call Close if the channel state is not
Faulted, and Abort otherwise. Now wrap a using around the proxy and only
keep it alive for the duration of a call.

I read conflicting reports on the overheads of creating a WCF proxy, but I
assumed it would be low and changed my code to "using" the proxy, and I
notice no performance change at all. My problem is solved because the proxy
can't time out if it doesn't exist.

Greg K

Reply via email to