You can run make all
to compile all files.
You can run make run
to run the server.
If you navigate to localhost:8088
in your browser you will be presented with the index.html page where you will be able to search for files on the server either by clicking the search button or by pressing the enter button.
Below is a list of files that are present on the server (to be prefixed with localhost:8088/
:
- css/style.css
- doc/CS1310.docx
- images/bb8.gif
- images/cat.jpg
- images/red.jpg
- images/tool.jpg
- images/background.jpg
- pdf/CV.pdf
- txt/dog.txt
If you search for a file that isn't present on the server you will be presented with the 404
page where you will be presented with the same search box and functionality as the index page.
You can run make test
to run the client.
Additionally you can add a url to the end of this command, i.e. make test localhost:8088/images/cat.png
which will overwrite the default url (pointing to a picture of a beautiful potato) and use the client to search for your specified url.
IF there are any problems running the commands please try to manually compile the java files by navigating to the server
and client
directories and running javac <filename>
.
To run the files, do the same and run: java <filename>
In order to see the returned headers via curl, add the -v
option, i.e. curl -v localhost:8088/txt/dog.txt
- Caching (via ETag hashing sending back 304 responses)
- Short and clean Client Implementation
- Interactive server homepage
- Interactive server 404 page