Question: Implement reliable file transfer protocol on top of DatagramSocket API provided by Java, i.e. Stop-and-wait 3.0. The implementation splits in to two parts running on

Implement reliable file transfer protocol on top of DatagramSocket

API provided by Java, i.e. Stop-and-wait 3.0. The implementation splits in to two parts running on different end systems:

Sender and Receiver.

The job of this distributed application is to reliably deliver a file from

Sender to Receiver. Sender program is an application with the GUI.

Minimal GUI requirements are:

A text-field to input

A text-field to input

A text-field to input

A text-field to input

TRANSFER button

A text-field to input (referred to as MDS later)

integer number for timeout (in microseconds)

A text-field to report

Receiver program is an application with the GUI. Minimal GUI requirements are:

A text-field to input

A text-filed to input

A text-filed to input

A text-filed to input

A field that shows the current number of received in

-order packets Additionally the Receiver must provide reliable/unreliable option which is explained later.

Sender will open the file, arrange handshaking exchange of messages with the Receiver, and send content of the file in the series of datagrams, each containing piece of data (no more than MDS

bytes) and a sequence number. Sender will also send special EOT (End Of Transmission) datagram (content of EOT datagram to be defined by you). Receiver will acknowledge every received datagram and save the data extracted from datagrams in file, using sequence numbers for proper reconstruction of the content of the file. File is delivered with no losses if it is an exact copy of the original file. At the end of transmission (when EOT is acknowledged) the Sender will report Total-Transmission-Time.

The reliable/unreliable mode of the Receiver is used to simulate lost packets: if the Receivers mode is unreliable the receiver will drop every 10th packet without sending acknowledgement for it. ACKs sent by receiver do not require the simulation of losses.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!