May be you have to specify the timeout value...check out the below link for details http://www.codeproject.com/KB/IP/xynetsocket.aspx
TCPView is a Windows program that will show you detailed listings of all TCP and UDP endpoints on your system, including the local and remote addresses and state of TCP connections. http://technet.microsoft.com/en-us/sysinternals/bb897437.aspx On Sun, Oct 18, 2009 at 1:37 AM, jeffbg123 <[email protected]> wrote: > > Hey guys, > > I am having a problem that is very mysterious and I would like some > advice as to how I should go about debugging it. > > So I have a program that basically reads live stock prices, stores > them and performs calculations on them and then outputs calculated > values. There are multiple threads of execution in this application. I > subscribe to prices using software that our company develops that uses > a socket connection to a price server. The application works great and > then about 5-60 minutes in, the subscription to prices gets dropped. > No exception is thrown, there is no output or anything. Simply the > prices start coming in. I wrote a very simple application that just > prints out the prices as they come in, and ran both applications. The > simple one works fine while my application stops getting prices. Both > are windows forms apps, and the app that stops getting prices, is > still alive, there are just no new updates to the GUI. > > I am completely baffled as to how to debug/troubleshoot this issue. I > have tried waiting for the freeze, performing a break-all in Visual > Studio, and examining the threads, but I cannot tell anything. I have > no idea where or when the error is taking place, and the only way that > I can tell is by seeing new prices on the other app, and not on the > malfunctioning app. The API through which I am getting prices provides > no way to check if my subscription is healthy or not. I have a button > that simply resubscribes to prices, and when the price subscription > drops, I can just click that button and everything works fine. > > Could this be a threading problem? Or is it more likely that it is > something else? I have monitored CPU/Memory/Network usage and > everything is running fine. What are the conditions under which a TCP > socket connection will be dropped? > > What are is the most probable cause of this problem and is there any > way I can easily use Visual Studio to pinpoint the issue? > > Thanks a lot, > > -Jeff >
