Enterprise web programming

Modules ENTWA (Level 6) and APSW (Level 7)

Web applications - specification

Website structure

  1. The webapp should include a page called /start.html. This should contain a link to the home page of the app (i.e. where users will normally start, e.g. index.xhtml, index.htm or index.jsp) and links to all documentation.
  2. Where possible, submit your work as a NetBeans project tree. Zip up the entire project directory structure containing your webapp.
  3. If requested, the following files should be located in the specified folders (or sub-folders thereof) relative to the project directory:
  4. Internal documentation, including requirements and design specifications /web/internal
    Javadocs /web/internal/javadoc
    Report (in either HTML or MS-Word format; PDF or plain text may be used as a last resort) /web/internal/report
    References and acknowledgements for code that is not your own work, or not original to this coursework (e.g. reused from a previous project you have done) /web/internal/ref
    JavaDB-compatible database creation script(s) (if you create or have modified a database schema) (in SQL format) /web/db
    Glassfish-compatible configuration /web/glassfish
    External documentation (e.g. user guides) /web/help
    Source code you have written for this coursework (please use package names starting with your name, e.g. "jim.projname") /src/java/<yourname>
    Source code you have taken from elsewhere /src/java/<package name>
    JAR libraries used (all assumed to be taken from elsewhere; document where you downloaded them from) /build/WEB-INF/lib

Database and security requirements

  1. Your application should use either:
    1. a database connection that I have provided; or
    2. if you have created your own, one where the (i) schema name; (ii) username and (iii) password are all the same and of the form <YourSurname><YourFirstInitial> (e.g. BRIGGSJ) or <Groupname> (e.g. GROUPA), and the scripts for creating the database are compatible with JavaDB.
  2. It is preferred that instead of using a script to setup the database, you:
    1. allow JPA to create the database tables on first use (set strategy to CREATE in persistence.xml)
    2. implement a user interface button that runs code to populate the database with initial and/or test data if it does not already exist
      1. alternatively implement a web listener class that runs on application startup, looks to see whether sample data already exists in the database and, if not, creates it using JPA persistence
  3. If the application requires any setup in Glassfish (e.g. a security realm), provide full instructions (e.g. a Glassfish control panel screenshot) on how this should be done. The name of the realm should be based on your user or your group's name, e.g. BriggsJRealm or GroupARealm.
    1. Alternatively (or in addition to the screenshot), include in your project folder (/web/glassfish) the part of your domain.xml file that contains the realm configuration. Don't include the whole file, just the relevant bits. On my machine, this file can be found in the folder C:\Program Files\glassfish-4.1\glassfish\domains\domain1\config
  4. The application should meet Java EE 7 (or later) specifications.

To see an example of a webapp that meets the above specification, download webapp appspec2.zip (2.6Mb).

If you have any questions about the above specification, please raise them with me as soon as possible to avoid problems. Don't leave it to deadline day!
 

Last updated by Prof Jim Briggs of the School of Computing at the University of Portsmouth

 
The enterprise web programming modules include some material that was formerly part of the WEB1P and WEB2P units.