This contains sample Java Client Server code to get the basic understanding. Run Server.java followed by Client.java to see it in action. This is configured to run on localhost in the present form. You can change host values to run them on separate machines.