-
Notifications
You must be signed in to change notification settings - Fork 0
phase 4
This document describes the requirements for the fourth and final phase of the Software Laboratory project.
Use the PostgreSQL Relational Database Management System, instead of SQL Server.
- Install PostgreSQL on the development machines. Alternatively, use a docker image (see
build.gradle
). - Obtain and use a JDBC driver for PostgreSQL.
- Change both the DDL and DML statements to use the PostgreSQL dialect.
- Use the
JDBC_DATABASE_URL
environment variable to configure the PostgreSQL connection settings.
Host the application on the Heroku.
- Create an Heroku free account. Heroku is an example of a Platform-as-a-Service (PaaS) provider.
- Install the Heroku CLI (Command Line Interface) on all the development machines.
- On the Heroku web site, create a new application
- The name should follow the following structure:
isel-ls-1920-2-g<número-do-grupo>
. - Select the "Europe" region.
- The name should follow the following structure:
- On the application home page, provision the "Heroku Postgres" add-on using the "Hobby Dev - Free" plan.
- The
JDBC_DATABASE_URL
environment variable will be automatically added to Java the execution environment.
- The
- Create the
Procfile
file withweb:
followed up by the necessary to start the application. - On the command line, do
heroku login
. - On the command line, inside the project root folder, do
heroku git:remote -a isel-ls-1920-2-gXX
. This will create a Git remote pointing to the Heroku repository.
The main goal for this requirement is to add support for the commands with POST
method in the HTTP interface.
For that, the representations for the following resources should be augmented with HTML forms:
-
/rooms
- form to add a new room. -
/rooms/{rid}
- form to associate a label to the room withrid
. -
/rooms/{rid}/bookings
- form to add a new booking. -
/labels
- form to add a new label.
Each one of these forms must, when submitted, send a POST request to the associated resource path. For instance:
- The representation returned on a
GET /rooms
request should contain a form with all the fields required to create a room. - This form, when submitted, must send a
POST
request to/rooms
containing these fields in the body. - If the
POST
request is successful, i.e. a new room was created, its response should be a303 See Other
with theLocation
header pointing to the created project (e.g./rooms/1
).
For this last phase, the project should stop relying on locally stored vendor JARs and use the Gradle supported dependency management system.
The completed project must be delivery until June 13 (end of week 15), via the creation of a 1.0.0
tag on the GitHub repository.
Improvements will be accepted until June 20, via the creation of 1.*.0
tags (functionality additions) or 1.0.*
tags (error fixes).
The final project evaluations will start on June 15.