dutn158 / Registration

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

API for Mobile Developer Test

This application provide Registration User Services.


1. Design approach

2. Workflow Diagram

3. Requirements

  • Java - 11.
  • Maven - 3.x.x.
  • Cockroach for dev, staging, prod environment.
  • H2 for local environment.
  • Docker.
  • Swagger UI.

4. Steps to setup

  • Build and run the application using docker
docker-compose up -d

Notes: If you are using Linux and facing a problem seem likes /bin/sh: ./mvnw: Permission denied

To do resolved that:

chmod +x mvnw

Run again: docker-compose up -d


5. Local development

6. Public API

7. Check test coverage and checkstyle

  • Build project: mvn clean install
  • Test coverage verification: mvn jacoco:check. Detail test coverage at least 70%, please go to folder {current_source_folder}/target/site/jacoco/index.html
  • Checkstyle: mvn checkstyle:check

8. Testing with Postman

  • I have attached postman file. You can import and testing with API for Mobile Developer Test Collection.

9. Recommendation

  • We can leverage docker to scale up and down by using containerized application.
  • To easily change logic, we can apply rule engine.

10. Test Driven Development

About


Languages

Language:Java 99.1%Language:Dockerfile 0.9%