This project is a JAVA Spring MVC application written as a code challenge for Software developer role, Basicallly it helps you perform simple conversions from US Dollar to 5 currencies while leveraging on the openexchange REST API.
Two basic features
- View your previous conversions
- Perform a new Conversion
- Registration Page
- Login Page
- Integration with openexchange
- Main screen
- Query History
- Main currencies (EUR, USD, GBP, NZD, AUD, JPY, HUF) and Naira
- Spring MVC
- JPA
- Fields - Firstname, Lastname, email, password, date of birth and address
- Integration tests (1, covers the conversion method)
- REST API -
/conversionOpenAPI doc available - Caching
- JMX setup
- Entirely based on Spring MVC and Thymeleaf, little or no javascript is required to run application
- Java(JDK) 8 or higher install java
- Maven 3 or higher install maven
- Database used is H2, No setup required, will create a local file named
testdb.mv.dbwhen application starts, Ensure you have a write access to current directory
- Clone this repository
git clone https://github.com/JohnTheBeloved/airtel-code-challenge.git - cd into project folder
cd airtel-code-challenge - compile :
mvn compile - Run tests:
mvn test - Build and Install the application:
mvn install - The exeutable jar file would be located in
target/airtel-currencyconverter-0.0.1-SNAPSHOT.jar
- Move the built jar to a location of your choice
- Execute the executable jar file:
java -jar airtel-currencyconverter-0.0.1-SNAPSHOT.jar
- The application is now running on http://localhost:8080
- Open your browser and access the http://localhost:8080
- Create the runnable Jar application archive (see developer section above)
- Run the Java application (see developer section above)
- Navigate to http://localhost:8080/register
- Put in your details to register and click on the registration button
- After successful registration, you are taken to the login page
- Upon succesful login, the home page is then displayed where you can see your previous conversions and also perform currency conversions
- To logout of the application, click on the logout link at the top left corner
- Yes, that's it. That all :) Thanks. Or if we have more time, we can add more features
- The currencies are provisioned when the application begins
- If currencies exist, the
application.propertiesvaluecurrencies.recreateis checked to see if the existing currency should be deleted and all currencies recreated - TO be continued...