Code Monkey home page Code Monkey logo

flowing-retail's Introduction

Sample microservices implementing order fulfillment

This sample application shows how to implement

  • a simple order fulfillment system

in the context of

  • Domain Driven Design (DDD)
  • Event Driven Architecture (EDA)
  • Microservices (µS)

with the concrete technologies/frameworks:

  • Java
  • Spring Boot
  • Spring Cloud Streams
  • Camunda
  • Kafka

Links

Overview and architecture

Flowing retail simulates a very easy order fulfillment system. The business logic is separated into the following microservices:

Microservices

  • The core domains communicate via messages with each other.
  • Messages might contain events or commands.

Note that every component does its own parts of the overall order fulfillment capability. As an example this is illustrated using BPMN and showing the Order and Payment Service with their processes:

Events and Commands

Run the application

  • Download or clone the source code
  • Run a full maven build
mvn install
  • Install and start Kafka on the standard port
  • Create topic "flowing-retail" (TODO: Auto Creation by Spring)
kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic flowing-retail
  • You can check & query all topics by:
kafka-topics.sh --list --zookeeper localhost:2181
  • Start the different microservices components by Spring Boot one by one
mvn -f checkout exec:java
...

You can also import the projects into your favorite IDE and start the following class yourself:

checkout/io.flowing.retail.java.CheckoutApplication
...

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.