MCS-270 Lab 4: JSP and MySQL

Introduction

In this lab, you will extend your work from the previous lab into the JSP architecture. In particular, you'll provide an interface which has two text fields in which the user enters the actor's first and last names, a radio button with which the user selects a store, and a submit button. When the user clicks submit, the two text fields are cleared, the radio button is left unchanged, and a table appears showing a list of titles of movies on the selected store's shelves which contain the selected actor. In addition to allowing the user to query your database, you can also provide you the ability to easily see more information about the movies, courtesy of The Internet Movie Database.

When I grade your labs, I will not just check that you have a correctly working application; I will also be looking to see that your application is well designed and documented. For this, I recommend that you follow the design process for the gened example I described in class. You also need to provide adequate documentation for the project, including in particular javadocs for your package.

If you wish, you may work in groups of two on the lab. (One group of three will be allowed, since there are an odd number of students in the class; however, if one, three, of five students want to work alone, then only groups of two will be allowed.) You should write the application from scratch, testing as you go. You should never be writing more than 10 or 20 lines of code before testing the code. Be sure you have a strategy for testing any code you write before you write it. If you need help with this, please ask.

How to set up and structure your project

What you'll submit

You'll submit a directory which is modeled after the gened application you have copied over. Here is a brief description of the directories/files you should include:

Optional

Feel free to add additional bells and whistles. For example, your list of movies could be links which search the The Internet Movie Database by title. If you decide to do this and want some hits, talk with me.

Grading

You'll be graded on what works, i.e., what I can test. If your application is not complete, you'd best be sure some portion of it does something which is measurable progress toward a completed application. For code which does something constructive, you will also be assessed on programming clarity and style. For instance, did you make appropriate choices about what fits in the jsp file, and what methods belong in auxiliary classes?

Submitting your code

To submit your code, do the following:

  • In a shell, go to the parent directory of the directory containing your Lab4 directory. Warning: You will probably have problems if this directory name has spaces in it, since Linux doesn't look kindly on so-named files/directories.

  • Assuming that the directory containing your solution is named Lab4, now type:
        ~karl/public/270/submit Lab4
    

  • Carefully review what the submit program prints out to confirm it seems to have submitted properly.