EssayGhost Assignment代写,Essay代写,网课代修,Quiz代考

EssayGhost-Essay代写,作业代写,网课代修代上,cs代写代考

一站式网课代修,论文代写

高质量的Assignment代写、Paper代写、Report代写服务

EG1hao
网课代修代上,cs代写代考
Python代写
您的位置: 主页 > 编程案例 > Python代写 >
代做Python:代写network CS2105作业代写 Assignment 1 - Python代做
发布时间:2021-07-25 15:27:36浏览次数:
Learning ObjectivesIn this assignment, you will implement a HTTP-like web server two functions: serving static files and providing a simple key-value store service. After completing this assignment, you should be able to (1) do simple network programming, and (2) have a good understanding of the mechanisms of HTTP.Group WorkThis assignment should be solved individually. However, you are allowed to form a team with another student (max. team size is 2) if you find it too difficult. Group submissions are subject to 1 mark penalty for each students.Under no circumstances should you solve it in a group and then submit it as an individual solution. This is considered plagiarism. Please also refer to the detailed explanations below for more information about plagiarism. Also refer to the special instruction below for submission of group work.We allow group work because some students might struggle to solve this assignment alone, especially when you are new to network programming. Do not give up, do not copy. Instead, form groups of two and solve the assignment together.Program SubmissionFor individual submission, please name your single source file as “WebServer- Student number .py” and submit it to the “Assignment_1_student_submission” folder of IVLE workbin. Here, the Student number is your matriculation number which starts with letter A. Anexample file name would be “WebServer-A0165432X.py”. If you use Java, C, or C++ to implement the web server, please use “.java”, “.c”, or “.cpp” respectively as the extension name. Note that the first and last letters of your student number should be capital letters.We recommend that you use Python 3 for the assignments. If you use Java or C/C++, we will compile and run your program for grading, using the default compilers on sunfire (g++ 4.8.4 or java 9.0.4). The used programming language is inferred from the file extension during grading. For a Java program, the class name should be consistent with the source file name, and please implement the public static main() method so that the program can be executed as a standalone process after compilation. Below screenshot shows respective language/compiler version on sunfire.network代写The deadline of submission is 10th March 2019 (Sunday), 6:00pm sharp. Please start early and submit early. You can always upload a newer version before the deadline. We strongly discourage students to submit their assignments only a few minutes before the submission deadline. The “Assignment_1_student_submission” folder will be closed exactly at the deadline, and all late submission should be made into a different folder named “Assignment_1_late_submission”. 1 mark of penalty will be imposed on late submissions. The later submission folder will be closed on 24th Mar 6:00pm sharp and there’s no acceptance of late submission afterwards.This programming assignment is worth 10 marks. Special Instructions for Group SubmissionFor group submission, please include both student numbers and name your source file as “WebServer- Student number1 - Student number2 .py” and submit it to the same folder as with individual submission. An example file name would be “WebServer- A0165432X-A0123456Y.py”. For each group, there should only be one designated member who submits the file (either one), in order to avoid problems caused by multiple branches within a group. Do not change the designated submitter! If the group needs to upload a new version, it should be done by the same designated submitter as well.Do not solve the assignment in a group and submit it as individual work. This is considered plagiarism. All submission will be subject to a thorough plagiarism check. Plagiarism cases will receive 0 mark. There will be no acceptance for excuses like forgetting to declare that they solved the assignment in a group.You are not allowed to post your solutions to any publicly accessible site on the Internet. Plagiarism WarningYou are free to discuss this assignment with your friends. However, you should design and write your own code. We employ a zero-tolerance policy against plagiarism. Confirmed breach will result in zero mark for the assignment and further disciplinary action from the school.You should refrain from having detailed discussions with other students. Additionally, you should not share notes. You should not allow anyone to look at your code. If you want to solve this assignment together, please do so but declare it as group work. The Web ServerIn this assignment, you are required to implement three components to form a HTTP-like web server. The first component is a simplified protocol modified from HTTP 1.1, which consists of the basic request-response mechanism and the persistent connection feature from HTTP 1.1, but with different header formats. On top of this protocol, a static file server and an interactive key-Figure 1: A layered architecture of the server. You need to implement the three components highlighted with bold fonts.value store is to be implemented under two different path prefixes. Figure 1 shows the overall architecture of the web server.The HTTP-like ProtocolThe basic mechanism of this HTTP-like protocol is the same as that of HTTP 1.1. That is, when the server accepts a new TCP connection from a client, it reads the request headers and an optional request body sent by the client, and then sends valid response headers and optionally a response body. After such a request-response cycle, the connection is persisted (not closing immediately), and the server waits for a new request from the client or a notification for closing the connection.For the simple scenarios in this assignment, the server only needs to handle the basic request and response information along with the “Content-Length” header field. Therefore, we simplify the header format of this protocol from that of the actual HTTP 1.1 as follows:All new-line (i.e. “ ”) and colon delimiters are replaced by single-space delimiters, as we do not have header components that contain spaces. Here, space is defined as the character with ASCII code 32. This means that the header is now a string consisting of non-empty substrings concatenated with a space in between, and that two consecutive spaces mark the end of header. The header string should contain only ASCIIEach header field consists of two substrings. The first is the case-insensitive name of the header field, and the second is the value of thisFor a request, the first two substrings are the case-insensitive HTTP method followed by the case-sensitive path. If there is a content body after the header, a “Content-Length” headerand its value follow the first two  Finally, the header is ended with two consecutive spaces. For example, the entire request could beGET␣/file/cs2105.txt␣␣GET␣/file/CS2105.txt␣␣POST␣/key/ModuleCode␣Content-Length␣6␣␣CS2105

所有的编程代写范围:essayghost为美国、加拿大、英国、澳洲的留学生提供C语言代写、代写C语言、C语言代做、代做C语言、数据库代写、代写数据库、数据库代做、代做数据库、Web作业代写、代写Web作业、Web作业代做、代做Web作业、Java代写、代写Java、Java代做、代做Java、Python代写、代写Python、Python代做、代做Python、C/C++代写、代写C/C++、C/C++代做、代做C/C++、数据结构代写、代写数据结构、数据结构代做、代做数据结构等留学生编程作业代写服务。