Skip to content

anandshah123/spring-cloud-demo

Repository files navigation

spring-cloud-demo

Architecture - Shopping Cart

Architecture

Modules

shopping-cart-commons

The common data transfer objects, being re-used in other projects

shopping-cart-customer-edge

Customer facing edge application. Interacts with two other microservices

  1. Promo services (shopping-cart-promo). Customer edge uses Feign client to consume this recommandation service. Ribbon performs client side load balancing and gets json from best fitting promo service instance after lookup to Eureka. In case of failure of all service instances it falls back to default promos thankx to Hystrix circuit breaker.
  2. Product service (shopping-cart-store). Customer edge uses Feign client to consume this service. Ribbon performs client side load balancing and gets product data from best fitting store service instance after lookup to Eureka.

shopping-cart-eureka-server

Manages service registration and discovery. Lists all available instances for store, promo etc services

shopping-cart-hystrix-dashboard

Keeps eyes on instances and their health (cpu, load, requests etc.). Breaks circuit in case of instance is failing requests too frequently or down for sometime. Collects event data from Turbine

shopping-cart-promo

REST servce to provide today's promotions based on recommandation algorithm

shopping-cart-store

REST service connected to the product database. Servers product listing queries.

shopping-cart-turbine

Collects SSE generated by all modules using Actuator

Instances and URLs

  1. Eureca server dashboard - http://localhost:8761/
  2. Hystrix dashboard - http://localhost:3001/hystrix
  3. Turbine stream - http://localhost:8989/turbine.stream
  4. Customer edge - http://localhost:3000/
  5. Recommendation engine promo - http://localhost:3002/promos
  6. Data store store - http://localhost:3003/products

About

A demo application for learning spring cloud using spring boot

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published