Hi Orline,
most probably you are using TcpClientChannel(0) at client side to get a
free tcp port for callbacks. There is a known problem that the channels
are closed a little bit late (1-10 secs) after the Socket.Close is
invoked. So basically you are running out of free sockets.
Hope that helps
Sunny
P.S. I nazdrave :)
> Hi!!
>
[quoted text clipped - 35 lines]
>
> Orlin
Sunny has a good point about the socket objects. If you take a look
at netstat -a -n from the dos prompt while this is happening you might
see a very large number of sockets popping up.
the solution for this isn't so much how to get more sockets rolling,
but rather to maybe think about the design a bit. Does it need to be
Singlecall when your just calling the same server over and over from
the same client? You might be better off with a CAO or SAO Singleton.
Allen Anderson
http://www.glacialcomponents.com
mailto: allen@put my website url here.com
>Hi!!
>
[quoted text clipped - 35 lines]
>
>Orlin
Orlin Popov - 31 Jan 2004 13:40 GMT
Hi Allen,
Thanks for your comment. It has been very helpful. Actually SAO singleton
shows exactly the same problem.
You are right. Netstat -a shows muliple sockets some in established state,
some in time-wait state. After they reach some limit program starts to
exhibit erratic behavior.
Actually this behavior with TCP channel is triggered when I use my own sink
between formatter and transport, both on client and server side. If I remove
that sink the TCP channel works fine(no multiple sockets generated). My
sinks exchange some out-of-band data in headers and modify streams a little.
I believe this is something with the TCP channel. If I switch to HTTP
channel everything is OK even with my sinks - only one pair of sockets is
crated and it is reused with every call.
What I need to understand is how a new sink can trigger such a wierd
behavior in the channel and Remoting when TCP channel is used so I can
understand what I am doing wrong. I have seen similar sinks working fine. In
theory a socket should be created for each thread that calls remote objects.
In my case I have just one thread that is doing repeated calls.
Thanks,
Orlin
> Sunny has a good point about the socket objects. If you take a look
> at netstat -a -n from the dos prompt while this is happening you might
[quoted text clipped - 48 lines]
> >
> >Orlin