CS 414/415 Programming Project 4 FAQ
Adrian Bozdog

Frequently asked questions:

  • Receiver-side implementation for stream-oriented protocol The receiver-side implementation for the reliable communication does not necessarily preserve the message boundaries. How should I implement the receiver ?.

    When an user application (e.g an application thread) uses minisocket_receive to receive application data, the application allocates a buffer of max_len bytes. If the minisocket used by the application has some data of lenght minisock_len received earlier from the sender than the minisocket_receive returns to the application min(max_len,minisock_len) bytes. If the used minisocket has not received application data yet, then the user application is blocked until the used minisocket receives some data. Then the minithread system of the receiver-side may wake up the blocked thread in two ways (you need to implement only one alternative):

    Hint: the receiver should not preserve packet boundaries. For example, if the application wants 100 bytes and the received packet has 1500 data bytes, then the application receives the first 100 bytes and the rest of the message from the packet is stored in the minisocket. Do not forget that application data is sent in order.

  • Getting a better grade How can I get a better grade for project 4 ?.

    You can get a good grade for project 4 by satisfying the following requirements:


    cs414@cs.cornell.edu