GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - dxc520/spring-cloud-event-sourcing-example: Spring Cloud reference application for building an online store as microservices that use event sourcing

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

33 Commits
33 Commits

Folders and files

NameName
Last commit message
Last commit date
account-service
account-service
 
 
catalog-service
catalog-service
 
 
config-service
config-service
 
 
discovery-service
discovery-service
 
 
edge-service
edge-service
 
 
hystrix-dashboard
hystrix-dashboard
 
 
inventory-service
inventory-service
 
 
online-store-web
online-store-web
 
 
order-service
order-service
 
 
payment-service
payment-service
 
 
shopping-cart-service
shopping-cart-service
 
 
user-service
user-service
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
cf-simple.sh
cf-simple.sh
 
 
docker-compose.yml
docker-compose.yml
 
 
pom.xml
pom.xml
 
 
run.sh
run.sh
 
 

Repository files navigation

Spring Cloud Event Sourcing Example

This reference application is a Spring Cloud example of using event sourcing in microservices. The project is intended to demonstrate end-to-end best practices for building a Netflix-like microservice architecture using Spring Cloud.

Tutorial provided here: http://www.kennybastani.com/2016/04/event-sourcing-microservices-spring-cloud.html

  • Spring Cloud OAuth2
    • Authorization Server
    • Resource Server
  • Edge Service
    • API gateway with OAuth2 protected resources
    • OAuth2 SSO
  • Event-driven Messaging
    • Event sourcing

Architecture Diagram

Online Store Architecture Diagram

Online Store Domain

This reference application is based on common design patterns for building an ecommerce application. The application includes the following microservices.

  • Discovery Service
  • Edge Service
  • User Service
  • Catalog Service
  • Account Service
  • Order Service
  • Inventory Service
  • Online Store Web
  • Shopping Cart Service

Usage

Microservice architectures commonly use multiple databases. The resources of the business domain are distributed across the microservice architecture, with each service having its own exclusive database. Each type of database for a microservice is commonly chosen by a development team based on its advantages when solving a specific problem.

This reference application uses the following mixture of databases.

  • MySQL - RDBMS
  • Neo4j - GraphDB
  • MongoDB - Document Store
  • Redis - Key/value Store

Integration Testing

If you would like to use Docker for integration testing, a docker-compose.yml file has been provided in the root directory. To build all the images, first make sure that you have Docker installed and available in your command line tool. With Docker and Docker Compose installed, execute the provided run.sh script. This script will build each container and start each of the services and database dependencies. When all the services have started up. Verify that the services are registered with Eureka at http://$DOCKER_IP:8761.

If everything has loaded correctly, navigate to the online store at http://DOCKER_IP:8787/. Click Login. You'll be navigated to the authorization server's gateway at http://DOCKER_IP:8181/uaa/login. The username is user and the password is password. You'll be authenticated and asked to approve token grant to the online web store. After accepting the grant, you'll be redirected to the online store application where you'll be able to access protected resources from the edge service.

License

This project is licensed under Apache License 2.0.

About

Spring Cloud reference application for building an online store as microservices that use event sourcing

Resources

Readme
Apache-2.0 license
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.