How to deploy these microservices in your local?
- Clone or Download this repository.
- Import all Projects in STS or Eclipse IDE.
- Update Maven dependencies.(Remove all workspace error)
- Build and Run the Projects in below sequence.
- 1st Deploy & Run eureka-server
- then Deploy & Run emp-service
- then Deploy & Run staff-api
- then Deploy & Run staff-web
How to run these microservices in browser?
These microservices having enabled springdoc-openapi or Swagger UI. You need to lunch staff-web project which runs in PORT:8090. Link : http://localhost:8090/
You can see all ms running intances in Eureka Server. Link : http://localhost:8761/
Other MicroServices Swagger links are given below :
emp-service link link : http://localhost:8000/swagger-ui/index.html
staff-api link Link : http://localhost:8010/swagger-ui/index.html
[If any of your server PORT (8000, 8010, 8090, 8761) is block then change the PORT number inside 'application.properties' (server.port=....) file with respective application.]
[staff-web] ----> [staff-api] ----> [emp-service]
The application eureka-server is service registry.
The application emp-service is core employee service with Mock data saved in H2 database.
The application staff-api is middle layer Staff Location API, consume data from emp-service.
The application staff-web is front-end UI application, developed using thymeleaf. It consumes data from staff-api
All microservices are connected (call other ms) using OpenFeign.more details..
Here Spring Cloud Sleuth provides Spring Boot auto-configuration for distributed tracing more details...