added multithreading to the socket server. the code in the server connection should be separated into other classes.