Skip to content

Microservices with Spring Boot and Spring Cloud(Eureka Naming Server, Ribbon, Feign, Zuul, Sleuth, Zipkin)

Notifications You must be signed in to change notification settings

azamakhan/Spring_boot_Microservices

Repository files navigation

Spring_Boot_Microservices

A simple Spring Boot microservices and Spring Cloud(Eureka Naming Server, Ribbon, Feign, Zuul, Sleuth, Zipkin).

The following has been implemented in this project:

  • Established Communication between Microservices, namely - Currency-exchange-service with Currency-conversion-service.
  • Centralized Microservice Configuration with Spring Cloud Config Server.
  • Simplified communication with other Microservices using Feign REST Client.
  • Implemented client side load balancing with Ribbon.
  • Implemented dynamic scaling using Eureka Naming Server and Ribbon.
  • Implemented API Gateway with Zuul.
  • Implemented Distributed tracing with Spring Cloud Sleuth and Zipkin.

How to use:

  1. Download the project

  2. Run pom.xml for project (mvn clean package)

  3. Run application.java in following order:

  4. Run NetflixEurekaNamingServerApplication.java

  5. Run NetflixZuulApiGatewayServerApplication.java

  6. CurrencyExchangeServiceApplication.java

  7. CurrencyConversionServiceApplication.java

  8. Example: http://localhost:8100/currency-converter-feign/from/EUR/to/INR/quantity/7500 and http://localhost:8765/currency-conversion-service/currency-converter-feign/from/EUR/to/INR/quantity/100

Ports

Application Port
Netflix Eureka Name Server 8761
Netflix Zuul API Gateway Server 8765
Currency Exchange Service 8000, 8001, ...
Currency Conversion Service 8100, 8101
Zipkin Distributed Tracing Server 9411
H2 Database 8000

URLs

Application URL
Netflix Eureka Name Server http://localhost:8761/
Netflix Zuul API Gateway Server http://localhost:8765/currency-exchange-service/currency-exchange/from/EUR/to/INR http://localhost:8765/currency-conversion-service/currency-converter-feign/from/USD/to/INR/quantity/10
Currency Exchange Service http://localhost:8000/currency-exchange/from/EUR/to/INR http://localhost:8001/currency-exchange/from/USD/to/INR
Currency Conversion Service http://localhost:8100/currency-converter-feign/from/EUR/to/INR/quantity/10000
Zipkin Distributed Tracing Server http://localhost:9411/zipkin/
H2 Database http://localhost:8000/h2-console

Note:

insert into exchange_value values(104, 1.19, 'EUR', 0, 'USD');

About

Microservices with Spring Boot and Spring Cloud(Eureka Naming Server, Ribbon, Feign, Zuul, Sleuth, Zipkin)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages