Alan Kaminsky Department of Computer Science Rochester Institute of Technology 4486 + 2220 = 6706
Home Page
Data Communications and Networks II 4003-541-70/4005-741-70 Spring Quarter 2006
Course Page

4003-541-70/4005-741-70
Data Communications and Networks II
Graduate Programming Project 1

Prof. Alan Kaminsky -- Spring Quarter 2006
Rochester Institute of Technology -- Department of Computer Science

Overview
Software Requirements
Submission Requirements
Grading Criteria
Late Projects
Plagiarism


Overview

Write a Java program for one node in an overlay network. The program is based on the RIT Overlay Network (RON) Router in the Computer Science Course Library. The program adds the following features to the basic router:

  1. The ability to compute routes automatically using a link state algorithm.
  2. The ability to trace the route from a source to a destination.


Software Requirements

Requirement 1. The program is called LSR (for "link state routing"). The program is run by typing this command:
 
java LSR <configfile>
 
where <configfile> is the name of the router configuration file. (Note: This means that the main program class must be named LSR, and this class must not be in a package.)

Requirement 2. When the program starts up, it configures a RON Router by reading commands from the configuration file specified on the command line. Each line of the file consists of one of these commands:

  1. setAddress <address> -- Set the router's RONP address.
     
  2. addInterface <intfid> <nearhost> <nearport> <farhost> <farport> <weight> -- Add a router interface with the given interface ID, near end host and port, far end host and port, weight, a data rate of 56,000 bps, and a maximum queue length of 1,000.
These are the same as the commands for the createManualRouter() method in class edu.rit.ron.RouterFactory, except there are no commands for configuring routes, and each interface's data rate and maximum queue length are fixed constants.

The weight is an integer greater than 0. It is used in the routing algorithm (see below).

Requirement 3. The LSR program uses the link state algorithm to compute routes automatically, as described in Comer, Computer Networks and Internets, Chapter 13. The distance metric used is the total path weight, where the individual link weights were specified in the router configuration files.

Requirement 4. The LSR program reacts to all network topology changes -- when a router comes up, and when a router goes down -- by recomputing the routes.

You will need to do some research into the practicalities of link state routing algorithms in order to write the LSR program. The book Interconnections, Second Edition by Radia Perlman (Addison Wesley, 2000) is a good resource. Also take a look at the Internet's link state routing algorithm, Open Shortest Path First (OSPF).

Requirement 5. Routing messages are transported in RONP packets with a transport protocol ID of 3. The design of the routing messages is up to you.

Requirement 6. The LSR program also implements an addition to the RON Control Message Protocol (RCMP). Two new opcodes are added to RCMP:

  1. Opcode = 2, Trace Route Request. When the transport layer entity sends a Trace Route Request message, the message initially consists only of the opcode. When a router receives a Trace Route Request message, either from a transport layer entity or from an incoming interface, the router appends the router's own RONP address (four bytes, most significant byte first) to the end of the packet. If the packet is destined for a different router, the router then forwards the packet as usual. If the packet is destined for the router itself, the router turns it into a Trace Route Reply message and sends it back to the original source.
     
  2. Opcode = 3, Trace Route Reply. The router merely forwards or delivers the Trace Route Reply message as usual.

Thus, Trace Route Request messages and Trace Route Reply Messages work similarly to Echo Request and Echo Reply messages. The Trace Route Request message accumulates the sequence of routers (RONP addresses) encountered as the message traverses the network. The Trace Route Reply message returns the list of routers back to the original source. The list consists of the source router, zero or more intermediate routers, and the destination router.

Requirement 7. After starting up and configuring the RON Router, the LSR program reads commands from the standard input and processes them. The commands are:

  1. send <address> <text> -- Send a message to the given destination address with the given text. When the destination LSR program receives this message, the destination LSR program prints:
     
    Message received from <address>: <text>
     
  2. ping <address> <text> -- Send an RCMP Echo Request message to the given destination address with the given text. When the RCMP Echo Reply message comes back to the source LSR program, the source LSR program prints:
     
    Echo reply received from <address>: <text>
     
  3. traceroute <address> -- Send an RCMP Trace Route Request message to the given destination address. When the RCMP Trace Route Reply message comes back to the source LSR program, the source LSR program prints:
     
    Trace route reply received from <address>: <router>-<router>...
     
    giving the list of routers in the Trace Route Reply message separated by hyphens.
     
  4. quit -- Quit the program.

These are the same commands as the edu.rit.ron.test.Test01 program, with the addition of the traceroute command.

Requirement 8. Unlike the Test01 program, the LSR program does not print any messages when the router performs internal actions.


Submission Requirements

Your project submission will consist of a Java archive (JAR) file containing all the Java source files for your project.

  • Each Java source file name must end in ".java".
     
  • Each class or interface must include a Javadoc comment describing the overall class or interface.
     
  • Each method within each class or interface must include a Javadoc comment describing the overall method, the arguments if any, the return value if any, and the exceptions thrown if any.

See my Java source files which we studied in class for the style of Javadoc comments I'm looking for.

Put all the source files into a JAR file named "<username>.jar", replacing <username> with the user name from your Computer Science Department account. The command is:

jar cvf <username>.jar *.java

If your project used classes from the Computer Science Course Library without modifications, you do not need to include the source files for these classes in your submission. If your project used classes from the Computer Science Course Library with modifications, you do need to include the source files for these classes in your submission.

Send your JAR file to me by email at ark­@­cs.rit.edu. Include your full name and your computer account name in the email message, and include the JAR file as an attachment.

When I get your email message, I will extract the contents of your JAR file into a directory. I will set my Java class path to include the following directories: the directory where I extracted your files, and the Computer Science Course Library directory. I will compile all the Java source files in your submission using the JDK 1.5.0 compiler. I will then send you a reply message acknowledging I received your project and stating whether I was able to compile all the source files. If you have not received a reply within one business day (i.e., not counting weekends), please contact me. Your project is not successfully submitted until I have sent you an acknowledgment stating I was able to compile all the source files.

The submission deadline is Tuesday, April 11, 2006 at 11:59pm. The date/time at which your email message arrives in my inbox (not the time when I actually read the message, which will be some time later than when it arrives in my inbox) will determine whether your project meets the deadline.

If you submit your project before the deadline, but I do not accept it (e.g. I can't compile all the source files), and you cannot or do not submit your project again before the deadline, the project will be late (see below). I strongly advise you to submit the project several days before the deadline, so there will be time to deal with any problems that may arise in the submission process.


Grading Criteria

50% of your project grade will be based on the design of your project as documented in the Javadoc and as implemented in the source code. Your project should:

  • Be designed using object oriented design principles.
  • Make use of reusable software components where appropriate.
  • Be documented using proper Javadoc style as described above.
  • Correctly implement the link state routing algorithm.
  • Correctly implement the RCMP Trace Route Request/Reply functionality.

50% of your project grade will be based on test runs of your project, with multiple processes each running the DVR program. The grade for this portion will be based on whether your project produces the correct output as specified in the Software Requirements. Every incorrect output will result in a loss of points. There is one exception: If your application does not run using the command line stated in Requirement 1, you will receive 0 points for this portion of your grade.

Any deviation from the requirements will result in loss of points. This includes errors in the output formatting (such as incorrect number of spaces, incorrect capitalization, or incorrect punctuation), misspelled output, and extraneous output not called for in the requirements. The requirements state exactly what the output is supposed to be, and there is no excuse for outputting anything different. If any requirement is unclear, please ask for clarification.


Late Projects

See the Course Policies for my policy on extensions.

I will not accept a late programming project unless you arrange with me for an extension. A late programming project will receive a grade of 0.


Plagiarism

See the Course Policies for my policy on plagiarism.

You may use any resources you wish to do the programming project, including resources discussed in class and resources you find on your own. You may discuss the programming project at a general level with others in the class. However, the programming project you turn in must be entirely your own work. You are not allowed to collaborate with anyone else on the programming project. You are not allowed to use any current or past student's work in any way when working on your programming project.

I will not tolerate plagiarism. If in my judgment the programming project is not entirely your own work, you will get a grade of 0 for the programming project. I will also place a report of the plagiarism incident in your permanent file in the Computer Science Department office. Repeated plagiarism incidents will result in disciplinary action in accordance with Computer Science Department policy and RIT policy.

There are only two exceptions to the prohibition on plagiarism:

  1. You may reuse without modification a source file from the Computer Science Course Library.
     
  2. You may take a source file from the Computer Science Course Library and add your own modifications, provided you state that you have done so and give credit to the original author.

Ad Hoc Networks 4003-543-01/4005-742-01 Spring Quarter 2007
Course Page
Alan Kaminsky Department of Computer Science Rochester Institute of Technology 4486 + 2220 = 6706
Home Page
Copyright © 2006 Alan Kaminsky. All rights reserved. Last updated 28-Mar-2006. Please send comments to ark­@­cs.rit.edu.