Spring Cloud Reference Doc[3.4.0]

- This documentation is created for reference from the Spring cloud POC we have developed in this turotial

00. Port standardization

Application Port Info
Limits Microservice 8080, 8081, etc. POC app developed
Spring Cloud Config Server 8888 It is default port for config srver as per spring docs.
Currency Exchange Microservice 8000, 8001, 8002, etc. POC app developed
Currency Conversion Microservice 8100, 8101, 8102, etc. POC app developed
Netflix Eureka 8761 Naming Server
API Gateway 8765 Entry point to all external requests.
Zipkin 9411 Distributed Tracing Server

01. SpringBoot cloud config server

Project ref: b2-sboot-cloud-config-server


02. Develop/Enable cloud config client

Project ref: b1-limits-service


3. RestTemplate: Connect to other mircoservice

Project ref: b4-currency-conversion-service

Note: When using RestTemplate we have to write boiler plate code to call rest service. To overcome this, we can use another spring dependency spring-cloud-openfeign.


4. OpenFeign client: Connect to other mircoservice

Project ref: b5-currency-conversion-service-openfeign

Note: The CurrencyConversion.java bean has all the properties which will be returned from `currency-exchange' service.


5. Service Registry / Naming server : Eureka naming server

Project ref: b6-naming-service


6. Eureka Naming server client configuration

Project ref: b3-currency-exchange-service & b5-currency-conversion-service-openfeign

Note: If Eureka client dependency is present in POM.xml, spring will automatically try to register this service to Naming server by looking for Eureka Server on it's default Eureka port - 8761.


7. Client side Load Balancing microservices

Project ref: b3-currency-exchange-service & b5-currency-conversion-service-openfeign

Note: With service name it finds the server details from Eureka Server. spring-load-balancer is mandatory dependency with feign client.


8. API Gateway

Project ref: b7-api-gateway

Note: This is an important note.


9. Routes with spring cloud gateway

Project ref: b8-api-gateway-routes

Note: When using routes in API Gateway, eureka discover client must be disabled in application.properties.


10. API Gateway : Global filter

Project ref: b8-api-gateway-routes


11. Using Resilience4j - retry

Project ref: b9-curcuit-breacker

Note: This is an important note.


12. Using Resilience4j - circuit breaker

Project ref: b9-curcuit-breacker

Note: This is an important note.


13. Using Resilience4j - API advance configuration

Project ref: b9-curcuit-breacker

Note: This is an important note.


End of document.