Login  
Search All Forums
Dart Home | PowerTCP Sockets for .NET | Custom Development Reply | PowerTCP Sockets for .NET (Secure and Standard) Topics | Forums   
AuthorForum: PowerTCP Sockets for .NET (Secure and Standard)
Topic: Connection Lost With No Warning
cehrnow

From: Cambridge, United Kingdom
Posts: 20
Member Since: 09/15/05
posted May 29, 2006 2:41 AM

In our application we're using BeginReceive() and EndReceive() and all works receiving a constant stream of data. However, after several hours, or even a day, the connection appears to get lost without any notification - ie. EndReceive() doesn't get called even though data still exists. If we restart the application it reconnects and continues receiving data.
Raj

From: Rome, NY, USA
Posts: 389
Member Since: 02/01/06
posted May 30, 2006 4:19 PM

There must be something breaking the connection.
1) Have you tried setting a higher timeout value than what you have now.
2) Have you checked the Trace Log, this can be created using Trace Event.
Refer the help file for info on this.

Let me know if you have further questions.
-Raj
cehrnow

From: Cambridge, United Kingdom
Posts: 20
Member Since: 09/15/05
posted May 30, 2006 6:54 PM

But if this is the case why is the ConnectedChangedEx event triggered ? Is there another event we should expect instead ?
cehrnow

From: Cambridge, United Kingdom
Posts: 20
Member Since: 09/15/05
posted May 30, 2006 6:57 PM

Meant to say why is the ConnectedChangedEx event NOT triggered ?
Raj

From: Rome, NY, USA
Posts: 389
Member Since: 02/01/06
posted May 31, 2006 11:21 AM

ConnectedChangedEx event will be triggered if the connection status changes during an active connection.
If the connection was not active (ie, the control was not in the act of sending or receiving data), then no event will fire until either
a) A send is attempted, or
b) KeepAlive is true, and the system is setup for Keep-Alive.
Also, regarding Keep-Alive, you might want to implement Keep-Alive on the system, as explained in the following article:
http://www.winguides.com/registry/display.php/891/

I hope this helps.
-Raj
Reply | PowerTCP Sockets for .NET (Secure and Standard) Topics | Forums   
This site is powered by PowerTCP WebServer Tool PowerTCP WebServer for ActiveX