Newsgroups : Borland : borland.public.delphi.internet.winsock : 2006 Nov : Best way to handle server drop disconnects

www.cryer.info
Managed Newsgroup Archive

Best way to handle server drop disconnects

Subject:Best way to handle server drop disconnects
Posted by:"Larry" (lkill..@charter.net)
Date:Wed, 29 Nov 2006 08:10:04

I am connecting to a DCB Etherpath Server in Raw mode.  DCB makes an
external re-232 to TCP/IP 2-way converter.
I have a the Kepp-Alive set to 15 seconds and I send a heartbeat to it every
6 seconds.  On occasion, I get a Socket Error  # 10054.  Connection reset by
peer.  Sometimes when I try to immediately I am hit with a connection
refused ... 10061.  I know know for sure but it may be coming while the
stack is being torn down and rebuilt by the server.

It is not throwing an exception in my client.  I have to do a Disconnect and
then reconnect.  Since I am not getting an exception,  I am not sure how to
handle this in code.

It is my intention to keep this connection 24/7.  This is an industrial
devise and as long as power is to it, I want to be connected to the server.

Thanks

Replies:

www.cryer.info
Managed Newsgroup Archive