I think, given the restrictions you’re put under (ie. not able to modify the
server to co-operate), you can’t really do what you’re asking within the TCP
alone.
What about creating an exterior process which does the ‘connected’
monitoring, and your TCP/IP application can use it to determine connectivity
before doing/aborting it’s work?
Besides, just because it left the network interface and went onto the wire,
doesn’t mean the other side got it (and if it’s currently stuck in
retransmit doesn’t mean the other side didn’t get it, it just means their
ack hasn’t arrived). Using pending packet counts (either in the stack or on
the interface) isn’t a reliable way of determining transaction
success/failure. Perhaps ‘TCPIP for Transactions’ is what you need (book by
Stevens).
-Adam
Paul Vander Byl <paul@gandacar.ca> wrote in message
news:b30kj8$9d$1@inn.qnx.com…
Yes. > > Everything in QNX is built using IPC. So when you send data to
on a non-blocking socket you are MsgSend()'ing that data to io-net.
So please tell me how setting NTO_TIMEOUT_SEND , and _NTO_TIMEOUT_REPLY
will affect the data sitting in the io-net send buffer?
Maybe I wasn’t clear. Obviously the write uses IPC to send the data to
io-net to be transmitted, but as my post says, the actual transmission
over
tcp is a blind send and it just waits to receive an ACK from the server.
It
doesn’t use MsgSend() for this, hence TimerTimeout(), NTO_TIMEOUT_SEND ,
and
_NTO_TIMEOUT_REPLY are useless in this case.
“Chris McKillop” <> cdm@qnx.com> > wrote in message
news:b30j5d$au8$> 1@nntp.qnx.com> …
Paul Vander Byl <> paul@gandacar.ca> > wrote:
I’ve looked at the TimerTimeout() and _NTO_TIMEOUT_SEND |
_NTO_TIMEOUT_REPLY.
I don’t think setting these options will help me in my case. These
calls
only apply to kernel specific IPC calls and are set per thread. When
I
write data on a non-blocking socket, it is dropped in the send buffer
and
another thread comes along and tries to send it. I also doubt that
the
thread trying to send the data is waiting on MsgSendv over the TCP
connection. It is just waiting for an ACK.
Am I totally wrong here?
Yes. > > Everything in QNX is built using IPC. So when you send data to
on a non-blocking socket you are MsgSend()'ing that data to io-net.
chris
\
Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I
get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/
\