Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

NOVA

Spring boot microservices application. Java + Kotlin + Vue + Keycloak

The application is a CRM tool for Telecom Providers. It allows to manage customers, plans, subscriptions, services, offers, and sales.

Design

The application consists of 5 microservices. CRM and Sales services are resources. API Gateway helps to connect resource servers under one endpoint. The authentication service contains the docker container for Keycloak. To let all of these services talk to each other, the Eureka server was used.

Links to repos

  1. Eureka server
  2. API Gateway service
  3. Authentication service(Keycloak in Docker container)
  4. CRM service
  5. Sales service
  6. Frontend service

Software requirements

  • Docker: Latest version
  • Git: Latest version
  • Kotlin 1.8 or later
  • Java 17 or later
  • Gradle and Maven: Latest versions
  • npm

Install Guide

The steps outlined below are specifically designed for the Windows Operating System. Different configurations may be necessary when building this application on MacOS or other operating systems. Therefore, please refer to the documentation for guidance on issuing commands in the corresponding operating system. Due to the application’s implementation using a Microservices architecture, each service requires individual cloning. The order in which these services are started is crucial for proper initialization. The recommended startup sequence is as follows:

  1. Eureka server
  2. API Gateway service
  3. Authentication service(Keycloak in Docker container)
  4. CRM service
  5. Sales service
  6. Frontend service To keep the project organized, create a folder to save all cloned repositories. After creating, move into the folder.

Eureka server

  1. Run this command in the terminal to clone the repository for the service registry:
git clone https://github.com/Asatillo/eureka-server.git
  1. Move to the eureka-server folder
  2. Run the command:
mvn spring-boot:run

API Gateway service

  1. Run this command in the terminal to clone the repository for the API Gateway service:
git clone https://github.com/Asatillo/api-gateway-service.git
  1. Move to the api-gateway-service folder
  2. Run the command:
mvn spring-boot:run

Authentication service

  1. Run this command in the terminal to clone the repository for the authentication service:
git clone https://github.com/Asatillo/authentication-service.git
  1. Move to the authentication-service folder
  2. Create .env file with the content:
POSTGRES_USER=admin
POSTGRES_PASSWORD=admin
POSTGRES_DB=keycloak_db
POSTGRES_LOCAL_PORT=5431
POSTGRES_CONTAINER_PORT=5431

KEYCLOAK_ADMIN_USER=kc_admin
KEYCLOAK_ADMIN_PASSWORD=kc_admin
# Port 8080 has to be free
KEYCLOAK_LOCAL_PORT=8080
KEYCLOAK_CONTAINER_PORT=8080
  1. Run the Docker container:
1 docker-compose up --build
  1. In your browser go to the http://localhost:8080. This should show you the main page of the Keycloak server.
  2. Click on the Administration console and log in with KEYCLOAK_ADMIN credentials written in the .env file.
  3. Click on Master and choose ‘Create realm‘. Click on browse and choose realm_export.json

CRM service

  1. Run this command in the terminal to clone the repository for the CRM service:
git clone https://github.com/Asatillo/crm-service.git
  1. Move to the crm-service folder
  2. Create .env file with the content:
MYSQLDB_USER=root
MYSQLDB_ROOT_PASSWORD=root
MYSQLDB_DATABASE=crm
MYSQLDB_LOCAL_PORT=3307
MYSQLDB_DOCKER_PORT=3306
  1. Run the docker container to access the MySQL database
docker-compose up --build
  1. Run the application:
mvn spring-boot:run

Sales service

  1. Run this command in the terminal to clone the repository for the sales service:
git clone https://github.com/Asatillo/sales-service.git
  1. Move to the sales-service folder
  2. Create .env file with the content:
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
POSTGRES_SALES_DB=sales_db
POSTGRES_LOCAL_PORT=5432
POSTGRES_CONTAINER_PORT=5432
  1. Run the docker container to access the PostgreSQL database
docker-compose up --build
  1. Run the application:
./gradlew bootRun

Frontend service

  1. Run this command in the terminal to clone the repository for the frontend service:
git clone https://github.com/Asatillo/frontend-service.git
  1. Move to the frontend-service folder
  2. Install all of the packages:
npm install
  1. Run the application
npm run serve

To ensure that all services are up and running, visit the following page: http://localhost:8761/

🪄 You can now access the application’s frontend page by navigating to http://localhost:8083 in your web browser.

Roadmap

  • Improving Navigation Performance with Caching
  • Use granular access control
  • Set up token lifecycle in the frontend
  • Enhance Scalability and Manageability with Docker and Kubernetes

About

Spring boot microservices application. Java + Kotlin + Vue + Keycloak

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors