Skip to content

Joshuapavan/RealWorldMicroserviceProject

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

E-commerce Microservices

A modern e-commerce application built using Spring Boot microservices architecture.

Services Architecture

The application consists of the following microservices:

  • Config Server - Centralized configuration management
  • Discovery Service - Service registry and discovery using Netflix Eureka
  • Customer Service - Manages customer data and operations
  • Product Service - Handles product catalog and inventory

Tech Stack

  • Java 21
  • Spring Boot 3.5.0
  • Spring Cloud 2025.0.0
  • MySQL Database
  • Flyway Migration
  • Maven
  • Lombok
  • JPA/Hibernate
  • Spring Validation

Prerequisites

  • JDK 21
  • Maven 3.9+
  • MySQL 8.0+
  • Git

Getting Started

  1. Clone the repository:
git clone https://github.com/Joshuapavan/RealWorldMicroserviceProject.git
cd EcommerceMicroservice
  1. Start the services in the following order:
# 1. Config Server
cd services/config-server
./mvnw spring-boot:run

# 2. Discovery Service
cd ../discovery
./mvnw spring-boot:run

# 3. Customer Service
cd ../customer
./mvnw spring-boot:run

# 4. Product Service
cd ../product
./mvnw spring-boot:run

API Documentation

Customer Service Endpoints

  • POST /api/v1/customer - Create a new customer
  • PUT /api/v1/customer/{id} - Update customer details
  • GET /api/v1/customer/{id} - Get customer by ID
  • GET /api/v1/customer - Get all customers
  • DELETE /api/v1/customer/{id} - Delete customer by ID

Project Structure

EcommerceMicroservice/
├── services/
│   ├── config-server/       # Centralized configuration
│   ├── discovery/          # Service discovery (Eureka)
│   ├── customer/           # Customer management
│   └── product/            # Product management
└── README.md

Features

  • Microservices Architecture
  • Service Discovery
  • Centralized Configuration
  • Database per Service
  • RESTful APIs
  • Data Validation
  • Database Migration
  • Cloud-Native Design

Development

Building

./mvnw clean install

Running Tests

./mvnw test

Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This Project is under MIT License

Authors

  • Joshua Pavan

About

A modern e-commerce application built using Spring Boot microservices architecture.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages