By Graham Hunter
The goal of the backend is to provide the system with persistant storage, manage the state of the system and allow functionality to be called remotely using URIs. It consists of:
  • REST Web Services.
  • A Jakarta Tomcat Web Server.
  • A mySQL Database.
+ Web Services

Web Services

The Web Services accepts HTTP requests, and responds with XML data. The interfaces then parse this data for presentation. Parameters are either passed in the URL or form encoded. The services available are split into four categories:
  • User Resources – Allows the creation and management of a user, such as adding a list, reminders or trusted users.
  • List Resources – Allows the creation and management of a list, such as adding items.
  • Item Resources – Items can be created, deleted and checked out.
  • Shop Resources – Shop layouts can be added, modified and deleted.
The Web Services were created using JAX-RS which allows the creation of Web Services using annotations. A sample method is given below.

@HttpMethod(value = "GET")
@ProduceMime(value = "application/xml")
public String User_Details(@QueryParam("UserId") int UserId) {

@HttpMethod – Defines what HTTP type the service should respond to, such as GET or POST.
@ProduceMime – What the response type will be such as plaint text or XML.
@UriTemplate – What URI the service should respond to.
@QueryParam – The name of the parameter sent with the URI

+ Web Server

Web Server

Jakarta Tomcat manages the connections to the database by:
  • Managing the connection pooling.
  • Monitoring for abandoned database connections and closing them.
Requests are handled by servlets. Each request is mapped to a servlet, which creates a new thread to process it.

+ Database


The backend uses mySQL, a freely available open source database. Each major entity in the system is mapped to a table as well as intermediary tables to link entities together.
  • Users
  • Lists
  • Items
  • Reminders
  • TrustedUsers
  • Shops
  • Layouts


The software model used in development was a feature driven model, where the overall system model is planned based on the initial features it needs, then features are implemented in order. There were two feature gathering stages, involving expert and non-expert users with a variety of shopping experience.


The backend was evaluated through many tests including functional and performance testing. The performance testing was done using JMeter to simulate multiple requests being made at the same time, and following a system use case.


The backend implemented all the features derived from user interviews and initial requirements. The Web Services provided an API that was easy to call and receive data from. The use of mySQL as a database meant that extra time was needed for development, as well as affecting performance. What was recommended was the use of Hibernate, which would manage persistence for the developer.