The backend of the feedback analysis application.
Name | URL |
---|---|
Group Report | https://drive.google.com/open?id=1mbjr1n2SyjgtVKfPI2wD-miIsA2EuCMv |
Technical Document | https://drive.google.com/open?id=17yByxnY16siJlCuh0ghhaaALpeEsluFE |
User Manual | https://drive.google.com/open?id=1fTtcK_afQHLy4fY02K0Pn4C1mNZCCNJK |
Name | URL |
---|---|
Trello Board | https://trello.com/segrp17 |
Document Repository | https://drive.google.com/drive/folders/1CePkA1cSuXFdGF-Pn8NyJPchsSWu4Yc2 |
Wiki | https://github.com/GRP-17/feedback-backend/wiki |
Deployment App | https://feedback-analysis-grp-app.herokuapp.com/ |
Development App | https://feedback-analysis-grp-app-dev.herokuapp.com/ |
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
JDK 1.8 - the project is written in Java.
Maven 3.x - this will handle any building, and dependencies. The Apache Maven build system can be found here.
Firstly, inside the project directory, run the following command in order to build the maven project:
$ mvn clean install
Secondly, in the same directory, run the following command to run the project:
$ mvn spring-boot:run
Congratulations! You should now be able to visit the site at: http://localhost:8080/
In order to test the backend without a frontend, open terminal and navigate inside the project folder (where test.json is) present.:
curl -X POST https://feedback-analysis-grp-app.herokuapp.com/feedback -d "@test.JSON" -H "Content-Type:application/json"
To skip using test.json, and specify your own:
curl -v -X POST https://feedback-analysis-grp-app.herokuapp.com/feedback -H 'Content-Type:application/json' -d '{"rating": 5, "text": "Your feedback test here"}'
.gitignore - defines files and file types to be ignored by git
.travis.yml - used to manipulate the travis ci pipeline & specify Heroku apps to push to
system.properties - used by heroku to specify the version of java we are using
BackendProject/ - folder is for the java project files and packages - this can be accessed using Eclipse
procfile - used by heroku to tell it what the dynos should run (just what it should 'host'/ run;
in our case it's a compiled jar file which starts the spring server)
pom.xml - the Maven build file, defines the build path i.e dependencies, plugins, etc.
Dependency | Version | Description | Usage |
---|---|---|---|
spring-boot-starter-web | 2.0.0.RELEASE |
Starter for building web, including RESTful, applications using Spring MVC. Uses Tomcat as the default embedded container. | Used to start the web application. |
spring-boot-starter-hateoas | 2.0.0.RELEASE |
Starter for building hypermedia-based RESTful web application with Spring MVC and Spring HATEOAS. | Used to start the web application. |
spring-boot-starter-data-jpa | 2.0.0.RELEASE |
Starter for using Spring Data JPA with Hibernate. | Allows the usage of JPA repositories for data storage. |
spring-boot-starter-test | 2.0.0.RELEASE |
Starter for testing Spring Boot applications with libraries including JUnit, Hamcrest and Mockito. | Used to provide JUnit testing within the startup. |
spring-boot-devtools | 2.0.0.RELEASE |
Provides additional development-time features. | Makes development more simplistic. |
junit | 4.12 |
JUnit is a simple framework to write repeatable tests. It is an instance of the xUnit architecture for unit testing frameworks. | Used to enable unit testing. |
mariadb-java-client | 2.2.5 |
JDBC driver for MariaDB and MySQL. | Used to allow connections to the MariaDB database. |
hibernate-validator | 6.0.13.Final |
Hibernate Validator allows to express and validate application constraints. The default metadata source are annotations, with the ability to override and extend through the use of XML. | Used to specify constraints in the data passed through, for example: the min & max rating. |
jaxb-api | 2.3.0 |
Provides a fast and convenient way to bind XML schemas and Java representations. | Used to map objects to XML. |
ibm-watson | 6.9.3 |
Client library to use the IBM Watson Services. | Used to analyse sentiments of text. |
jackson-databind | 2.9.4 |
General data-binding functionality for Jackson. | Used to map objects to JSON. |