/bookshop-microservices

A simple online bookshop built to demonstrate the implementation of microservices architecture.

Primary LanguageJava

A Simple Bookshop

A simple bookshop API.

Brief Description

A simple bookshop implemented to practice and aid understanding of concepts learnt in building Microservice Architecture.

The features are summarized below:

  • Create/Read staff
  • Create/Read books
  • Sell books
  • View sales

Software Architecture

The Microservices Architecture for this project is illustrated in the diagram below:

Bookshop Architecture

Getting Started

These instructions will get you a copy of the project up and running on your local machine for testing purposes.

Prerequisites

System requirements for this project to work includes:

  • Java Development Kit (JDK) (v8 or higher)
  • Maven
  • MySQL(v5 or higher)

Installation

To install the dependencies in the pom.xml, click on the "import changes" prompt after each service folder contained in the project folder has been opened.

Running the project

To run the project on your local machine, run the following files concurrently in the following service directories:

  • BookshopEurekaServerApplication.java
    bookshop-microservices/bookshop_eureka_server/src/main/java/com/emeka/bookshop_eureka_server/

  • BookshopInventoryApplication.java
    bookshop-microservices/bookshop_inventory/src/main/java/com/emeka/bookshop_inventory/

  • BookshopSalesApplication.java
    bookshop-microservices/bookshop_sales/src/main/java/com/emeka/bookshop_sales/

  • BookshopStaffManagementApplication.java
    bookshop-microservices/bookshop_staff_management/src/main/java/com/emeka/bookshop_staff_management/

  • ZuulServiceApplication.java
    bookshop-microservices/zuul_service/src/main/java/com/emeka/zuul_service/

The various services can be tested via Postman with the following URLs:

In addition, the Eureka Server UI can be visualized in the web browser via the URL: http://localhost:8761

Built With