Re: Howto find multiple servers using TCP
- From: "AliR \(VC++ MVP\)" <AliR@xxxxxxxxxxxxx>
- Date: Wed, 12 Dec 2007 16:06:37 GMT
No only UDP. But the Multicast is only there for the server finding and
then you would want to switch to a normal TCP socket once you find the
server.
AliR.
"amccombs" <amccombs@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:902C317D-01C5-4FE1-97D9-B93F04749975@xxxxxxxxxxxxxxxx
Can you multicast on TCP?
"AliR (VC++ MVP)" wrote:
I can't think of another way.
But if the server program is your program, then I have a suggestion.
I have a server that alot of clients connect to, and I really didn't want
to
have to input the server address in every client. So what I did was I
used
a multicast socket to find the server. The server listens to traffic on
a
particular multicast address, and when the clients want to find the
server
application, they would send a message (where are you) using a multicast
socket with that particular address, the server would receive the message
and send a reply (Here I am) with its IP address. Now if there are more
than
one server, the client would get multiple "Here I am" replies. This
entire
process takes less than a second.
AliR.
"amccombs" <amccombs@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:129DBBB8-AD79-4588-91E0-0DF847EB11FB@xxxxxxxxxxxxxxxx
I have to search my subnet to look for servers that are listening on
port
30715. I am using one thread of a derived class of CAsyncSocket. I am
using
CEvents with a 200 milisecond timeout, if there is no connection within
the
200 miliseconds, then I know there is no serer. However searching from
192.168.1.1 to 192.168.1.254 takes a long time. Is there a better way?
.
- Follow-Ups:
- Re: Howto find multiple servers using TCP
- From: amccombs
- Re: Howto find multiple servers using TCP
- References:
- Re: Howto find multiple servers using TCP
- From: AliR \(VC++ MVP\)
- Re: Howto find multiple servers using TCP
- Prev by Date: RE: DoModal for a CWnd derived?
- Next by Date: Re: Toolbar not opening
- Previous by thread: Re: Howto find multiple servers using TCP
- Next by thread: Re: Howto find multiple servers using TCP
- Index(es):
Relevant Pages
|