Re: Socket communication issues.
- From: "Richard Maher" <maher_rj@xxxxxxxxxxxxxxxxxx>
- Date: Sun, 25 Feb 2007 20:19:41 +0800
Hi K2,
Currently, the client has no idea this event has happened, so it will
attempt to write to the outputstream and then wait for an excruciatingly
long time for the reply on the inputstream before finally timing out.
I found setSoTimeout (won't help your writes) and setKeepAlive but no
tcpProbeIdle tcpDropIdle or soFullDuplexClose. Curious.
The demo example I'm currently knocking up doesn't check for -1 on the Write
but nonetheless it completes immediately when I kill the server process. And
the subsequent Read reports an immediate error. My server is not Java and I
do have the FullDuplexClose option set their.
Regards Richard Maher
"k2" <karlkras@xxxxxxxxxxxxxxxxxxxxx> wrote in message
news:err41f0pli@xxxxxxxxxxxxxxxxxxxxx
Hello,
Scenario... Client connects to server socket, no problem sending
transmission packs back and forth...
Somewhere during this communication the server socket closes for any
number of reasons.
Currently, the client has no idea this event has happened, so it will
attempt to write to the outputstream and then wait for an excruciatingly
long time for the reply on the inputstream before finally timing out.
Shouldn't there be some indication that the socket has died on the
server? Client socket check for isConnected is still true after this
event, so it carries on as if there's something listening on the other
end when in fact it isn't. Is there some basic cleanup that the server
should be performing during its shutdown process in order to cleanly
sever the communication?
thanks,
K2
--
*****************************************
Please remove the killspam portion of
my return address if replying directly
*****************************************
.
- References:
- Socket communication issues.
- From: k2
- Socket communication issues.
- Prev by Date: Re: NewBee help with HashMaps
- Next by Date: Getting Started with Bluetooth
- Previous by thread: Re: Socket communication issues.
- Next by thread: Specify lib dir on command line
- Index(es):
Relevant Pages
|