By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
432,306 Members | 1,657 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 432,306 IT Pros & Developers. It's quick & easy.

Socket and Internet programming practices

P: n/a
Hi,
I'm wondering what the industry practices are for socket and internet
programming. Can you provide any links to good articles on network
application architecture? I have found many tutorials, but most don't get
into the detail I desire, and are very very simple TCPClient/TCPListener
implementations. I haven't found any great literature on how production-level
data transmisison applications are made.

For example, suppose I'm making an instant message, and file transfer
application, should this application be connection based TCP, or
connectionless UDP?

If a server portion of this application can support mutliple clients, should
these clients be on separate ports, or should all the listening be done on
one port?

What are the general data transmission techniques? I have been experimenting
with fixed-length byte arrays with first byte being type of data, second
through fifth bytes being length of data coming, then the data following.

How does one deal with the data exchange between classes in a
socket-transfer application? For instance, incoming data needs to be dealt
with, an event could be generated with the incoming data, but then the thread
that was receiving data from the socket would be the thread that fires the
event (and delegates attached to the event) blocking any more data from
coming into the socket. I have implemented a queue, with a dedicated event
thread to process the events in the queue, is this an acceptable practice?

Is a TCP socket connection full duplex, so a separate thread can be blocking
at receive() while a thread sends() bytes? How about UDP?

What methods,tips, and tricks are used to measure kbps transfer speeds?
Especially with fixed-length packets as described above?

Thanks for any input on this subject. I have a great deal of experience
programming, and when I take on a new hobby project, I run into a barrage of
questions like this, and can usually find great answers around the
net/newsgroups, but this topic seems sparse with user input.

Thanks in advance,
Andrew

--
Andrew Arace
Software Engineer
Nov 16 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Bump.
I thought this was a moderated group?

Nov 16 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.