On Next Friday, Oct 19 you must hand me a printed description of what functions you have implemented from the interface and what SQL each function uses.
Your goal in this project is to learn about database schemas and how to create a persistence layer that isolates an application from the underlying SQL and a specific database vendor. You must create an implementation called StorageService that implements interface StorageLayer, which I will provide to you below. Such a service could be used as part of a link manager application, such as the PeerScope.com system I described in class.
You are to create the necessary SQL table creation statements necessary to create the following schema. The key symbol on the left side of the column names in the following diagram indicate that they are primary key(s) for that table. Also note that most of the fields to be listed as NOT NULL. Further add constraints such that the ID and EMAIL columns are unique. Use the MySQL REFERENCES syntax to link tables for the foreign key relationships.
Here's some sample data
In order to build this library, you must have access to a MySQL database. To facilitate this, you will be given an AWS machine again upon which you must install mysql mysql-server using yum. Then, you must configure it to have user and so on that you can use. Use whatever username that you want as it will be just you testing it on this database. (You will have to investigate how to administer MySQL.)
You will create a jar file called db.jar containing *.class files and place it in a directory called db dist under your cs680 dir:
Pur your source Java code in db/src:
To jar your stuff up, you will "cd" to the directory containing your source code (perhaps db src) and create the jar in the db dir:
All classes must be in the default package!
To learn more about submitting your project with svn, see Resources.
You must submit your source code for credit.
Your project must start up exactly like this:
You may discuss this project in its generality with anybody you want and may look at any code on the internet except for a classmate's code. You should physically code this project completely yourself but can use all the help you find other than cutting-n-pasting or looking at code from a classmate or other Human being. There is a lot of sample code out there for implementing Java proxies, but they all are these massive programs that use lots of helper objects. For example, my program doesn't use any helper classes except for the Runnable client handler. I've looked at most of these solutions on the web and I will be very suspicious if I see a similar coding pattern. You must implement this yourself.
I will deduct 10% if your program is not executable exactly in the fashion mentioned in the project; that is, class name, methods, lack-of-package, and jar must be exactly right. For you PC folks, note that case is significant for class names and file names on unix! All projects must run properly under linux at amazon.