15-441 Project 2 -- Checkpoint 1
Checkpoint 1 is worth potentially 5 total points out of 100 towards
Project 1. The work started here, when completed, will be worth 40 total points
out of 100. To receive the points and begin working on Project 1 you must:
Useful Resources:
- Full REQ/RESP protocol definition for RD <--> Web Application
- Find a project partner
- If you are unable to find a project partner, the bboard is a great resource. Post there or look for posts seeking for project partners.
- If you are still unable to find a partner then email Athula.
- Create a private project using git as the source control system.
- Read and understand the entire project statement. The project document is a living document since this is a new project. Keep looking for updates.
- Get the new starter package from here.
- The starter package includes along with other files, a new index.html and some static files. The index.html has two new webforms.
- Webform 1 is used to query the Distributed HTTP service for an object. If you inspect webform 1, it submits the object name entered by the user and does GET on /rd/<port>
- Webform 2 lets you add a new object and upload a file corresponding it to it to the local server. If you inspect the webform 2, it posts to /rd/addfile/<port>
- The <port> here corresponds to the local port that is used for communication between the flask application and the routing daemon and you may change it manually in the html file, but make corresponding changes to the config file of the routing daemon. Also feel free to change the index.html file as long as it has two webforms performing the specified tasks.
- Use the default webserver that comes with Flask. Do not use your Liso webserver from Project 1.
- We have implemented the webserver (webserver.py) for you in the starter packagae.
- Implement a flask web application
- You will find the skeletal code for implementing the required features in webserver.py. The details of the features that need to be implemented are also provided in the code.
- Implement parts of the routing daemon
- The routing daemon loads and parses the config file and file list file on bootup and keeps a list of the local objects and their relative paths. Sample config file (node1.config) and file list file (node1.files) is provided in the starter package.
- It needs to listen on the local TCP port for any incoming requests from the flask application
- On a GETRD request for an object, it needs to parse the file list and construct the complete URL using the peername, liso server port and relative path information and send the URL to the flask application
- On a ADDFILE request, it needs to add the objectname and relative path information to its file list.
Files we expect to see in your 'git tag checkpoint-1 xxXXxxXXxx' (fill in the x's with the commit you want to submit, don't forget to push!):