The object of this project is to implement a model computational offloading where a single client issues three parameters(Link ID, PacketSize, and Signal Power) to the AWS server and expects the reply for the end-to-end delay of the designated link. The time consumed during the process will be calculated based on the Shannon's channel capacity formula and the given parameters.
Some explanations for the project: a. What have been done in this assignment? In this project, I realized two client programs, one AWS server, and three backend-servers used to realize socket communication over TCP and UDP protocol. The client could send the data , , and to the AWS server, and the AWS server will forward the inputs to backend servers via UDP socket communication. Backend server A and backend server B will retrieve the link information then reply the information to AWS. After received corresponding information from backend server A and backend server B, the AWS server will forward the information to backend server C, which is a computational server. The backend server C will calculate the , , and delay according to the information provided by AWS server, then it will reply the result to AWS. After received the results, the AWS server will forward the end-to-end delay to client and all calculated results to monitor, respectively.
b. what the code file are and what each one of them does? 1. client.c: This is the code file of the client. The client sends three information including the , , and to the AWS server. The connection between client and the AWS server is based on TCP. 2. monitor.c: This is the code file of the monitor program in this project. The monitor could be monitoring all activities conducted in this project. All of the computational results from backend server C will be transferred to monitor from AWS server via TCP connection. 3. serverA.c: This is the code file of the backend server A. The communication between backend server A and AWS is based on UDP protocol. Backend server A will receive the link number which inputted by client from AWS, and retrieve the corresponding information related to link number in the °∞database_a°±. Once the backend server A found the information, it will reply it back to the AWS. 4. serverB.c: This is the code file of the backend server B. The communication between backend server B and AWS is based on UDP protocol. Backend server B will receive the link number which inputted by client from AWS, and retrieve the corresponding information related to link number in the °∞database_b°±. Once the backend server B found the information, it will reply it back to the AWS. 5. serverC.c: This is the code file of the computational server C. The computational C will receive the retrieved information by server A or server B from the AWS server. Once it has received the information, it run the calculation function to calculate the delays. The, it will send the result back to the AWS server via UDP socket communication. 6. aws.c: This is the code file of the AWS server. The AWS server will perform the role of transfer station. It receives the inputs from the client and forward the inputs to the backend servers. Also, it will carry the retrieved information from searching server A and server B and forward the information to the computational server C. Finally, the AWS server will forward the results it received to the client and the monitor.
c. The format of all the messages exchanged.The message inputted by the user are in the type of char. The messages transferred between the AWS server and the backend servers are type of double or char based on the different situation. The format of the information read from the .cvs documents are char, the final result exchanged among AWS server, client, and monitor are double.
d. After testing many times, the programs is so far so good. However, there may be some errors and failures that I have not found yet. What is worth to mention is that the backend servers are seem kept still even if a new round test has begun. However, this is just because the interface showing on screen between different round are totally same when correct inputs were entered, only some numbers are different such as the sentence: <0> / <1> matches found. When the user input wrong numbers (negative values for size and link number), the client will give prompt says that it should be in the right format.
e. In this project, I referenced the Socket Tutorial by Robert Ingalls.
f. All rights are reserved for this project, please don't copy the code without permission.