CIS 6930-01
Fall 2000

Homework #4

A Simple Client/server application

    An RMI-based Server

    You are asked to write a client/server-based Java application, for manipulating entries in a text file. The text file should reside on a remote server, and the client program should run on a computer elsewhere on the Internet. Communication between client and server should go through RMI.

    You should design a suitable remote interface through which the client can read and write to a data file on the server machine. For simplicity, limit the interface to operations for reading the whole file and writing the whole file (in single invocations). You may base your interface on the FileSource example discussed in the lectures, if you wish (you may only need to add one method for writing).

    It is recommended you run the server implementing this interface on sirah, merlot or cabernet in CSIT.

    The client program may be one of:

    1. A Swing applet, adapted from the program you produced in Homework III. The JFrame should be converted to a JApplet, and calls to your remote interface should be added for reading from and writing to the data file on the server machine. To view your applet you will need access to an Internet-connected computer, probably with the Java 2 browser plugin installed. This will be discussed in the lectures.
    2. A Swing application, adapted from the program you produced in Homework III. Calls to your remote interface should be added for reading from and writing to the data file on the server machine. To run your client application you will need access to an Internet-connected computer, with the a suitable version of the Java Development Kit installed.
    3. A Java 2 application with a command-line based interface (no GUI). This interface should at least display all entries in the file, and give you an option to add new entries. It should include calls to your remote interface for reading from and writing to the data file on the server machine. To run your client application you will need access to an Internet-connected computer. If necessary you may telnet to one of the course hosts mentioned above (not the same host running the server!) and develop and run you client there.
    Option 3 is only recommended for people who do not have access to a computer equipped with the right software to make 1 or 2 possible, or people who did not complete Homework III. If you completed homework III, options 1 or 2 should be less work: this is supposed to be a relatively short exercise in getting an RMI based program running. It should not involve extensive new coding.

    To submit your homework, include

    To submit the homework you should copy these files to /home/project/it1fall00/homework4/login/ on sirah, where login is your login id (user name) on this machine.

    If you write an applet, you are encouraged to deploy class files and data files in the directory /home/httpd/html/users/login/homework4/ on sirah, where login is your login id (user name) on this machine. You should then be able to view the applet at a URL of the form:

    http://sirah.csit.fsu.edu/users/login/homework4/...

    Further advice may be added to this page as the submission deadline approaches ...


    Please send questions to Bryan Carpenter at dbc@csit.fsu.edu.