Multi-Client Server

Working on the server software some more, with some help from a friend, it now accepts up to an arbitrary (currently 10) connections, each one handled in its own thread. When the server manager gets a new connection, it passes the Socket to the new thread, which then handles all the I/O for that connection. When that client disconnects, it sets a ‘in use’ flag, which the server manager can then use to re-allocate it if all the other threads are busy.

Here’s a demo image! I’ll also release some source code for this stage, as a simple proof of concept before it gets too much more complicated.


The next step is to set up server sending messages from one client to another, and become a real server! At the moment its just a listener…

Here’s a link to the source code.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: