Here is the assignment verbatim:
1.) Write a Java program that is a TCP server that
returns a HTTP response to a browser that displays
the client’s IP address and the number of times it has
connected to the server.2.) Test your program with a standard Web browser like
the Internet Explorer.
So far in the class we’ve been creating servers and clients in java to send images from client to server. We have been using command prompt/terminal to compile and run all programs.
What it seems like to me is we create the Server and Client java programs but this time the client just connects and disconnects and the Server gets the IP address and returns the http response.
Basically what I’m looking for is your interpretation on what to do for the assignment. Also any insight on what a HTTP response exactly is/does would be nice.
Thanks.
The assignment is asking you to write a server that implements the HTTP protocol.
As such, you will be able to use any HTTP client, such as Google Chrome.
You don’t need to write your own client.