CSE 461 Project 1


Reliable, Stream Oriented Communications using the Sliding Window Protocol

Due 5:00 pm, Thursday, 29 October 1998

Note: this assignment is to be done in groups of 2-3.

In this assignment, you will use a network simulator to implement and experiment with reliable communication protocols. The simulator will simulate a 'typical' internet link, with variable bandwidth and latency, packet reordering, and drops. These parameters are all configurable.

What you need to implement is a reliable sliding-window communication protocol. Your protocol should be able to correctly handle dropped and reordered packets, and extract a bandwidth as close as possible to the potential bandwidth on the link. The potential bandwidth is defined as:

For Selective Acks

mean bandwidth * (1 - packet drop rate)

For Go Back N

mean bandwidth / (1 + packet drop rate * window size)

The default network parameters are:
Paramter Default value Allowable values Flag
MTU 20 bytes ?
Timeout 1 ms ? timeout=<value>
Bandwidth 1.0 Mbit/sec 1.0 - 100.0 Mbit/sec bandwidth=<value>
Bandwidth SD 0.2 Mbit/sec 1/5 bandwidth -no-bandwidth-variation
Bandwidth Walk 0.5 0.0 - 1.0 bandwidth-walk=<value>
Latency 2 ms 1 - 100 ms latency=<value>
Latency SD 0.5 ms 1/4 latency -no-latency-variation
Latency Walk 0.5 0.0 - 1.0 latency-walk=<value>
Drop Prob 0.25 0.0 - 0.25 drop-prob=<value>

Turning off latency variation prevents reordering of packets. SD is standard deviation (the quantities are normally distributed). Walk is the tendency of the value's mean to walk with time. 1.0 is the maximum, 0.0 will keep the mean fixed thorugh time.

Provided Code

NEW!A brief description of the simulator interface is available here.

You are provided with an implementation of a simple stop-and-wait protocol. This is a particularly inefficient protocol (the choice of timeout is particularly poor), and gets somewhere on the order of 3% of the available bandwidth. Nevertheless, you will probably want to use it as a starting point for your sliding window protocol. The major reason for this is that this implementation gives you a bunch of pieces which are really useful for building send and receive algorithms.

The code that you are provided has been divided into the following packages:

The code that you would want to modify is SAWSender.java and SAWReceiver.java in order to implement the sliding window protocol. The code is available in two distributions: a zip file for Windows/Visual J++ and a tar file for Unix. The only differences are the CR/LF convention on the source files, and the workspace/makefile setup: