Application that cleans records, adds to a database, and then allows users to filter and select data using an API
Software Requirements
- JDK 17
How to use
-
Clone/Download project from GitHub
-
From the command line run this command to have default film data:
java -jar IMDB-Movies-API-0.0.1-SNAPSHOT.jar
-
From the command line run this command to use your own csv of film data:
java -jar IMDB-Movies-API-0.0.1-SNAPSHOT.jar "insert your file path here"
-
To access the database open up a browser and navigate to
- JDBC URL to log into the H2 console:
jdbc:h2:mem:IMDBFilmsTestDB
- Username:
sa
- There is no password
- Hit connect to log into H2
- JDBC URL to log into the H2 console:
-
You can hit the endpoint
localhost:8080/getFilms
to call the API and return all films -
You can also hit the endpoint
localhost:8080/getFilms/{Title}
where title can be a single letter to return all the films that begin with that letter or a string of letters which will return all the films which contain the string pattern in the title.
A sample of the data can be found at:
- Column 1 => Movie title as a String.
- Column 2 => IMDB Score as a double.
- Column 3 => Movie release year as an Integer.
- Column 4 => Movie duration as an Integer.
- Column 5 => Movie Age ratings as a String.
- Column 6 => Movie budget as a Long.
- Column 7 => Movie genre as a String separated by |, e.g Action|Adventure|Comedy.
- Column 8 => Movie gross as a Long.
- Column 9 => Director's name as a String.
- Column 10 => Actor one as a String.
- Column 11 => Actor two as a String.
- Column 12 => Actor three as a String.
- Column 13 => Movie Language
- Column 14 => Movie Country
How to run Test Run the following on the terminal
> mvn clean test
Cucumber used for end to end tests
The image shows the cucumber test report which shows that film data from csv has been loaded successfully*
- Junit used for unit testing giving above 80% coverage
- Quality Gate used to check the overall code quality
*add how we tackled this project, the steps we took and what order, optional as it can be combined with diffictuties.
add details of any issues
any useful links
Jack Mardell, Daniel Webb, Mustapha Chedid, Luke Homer, George Heath, Youmna Khan, Ahmad Abubakar,Adil Salamat