This repository contains the CurrencyExchange application, which is currently being converted from a monolithic architecture to a microservices-based architecture. The project is built using the Java technology stack, leveraging Spring Boot for rapid development and MySQL for database management.
The SocialMedia application is being modularized into several microservices for improved scalability and maintainability.
- Currency Conversion Service
- Currency Exchange Service
- Limit Service
- Programming Language: Java
- Frameworks: Spring, Spring Boot
- Database: MySQL
- ORM: JPA, Hibernate
- REST API Development: Built using RESTful principles
- Eureka Naming Server: For service discovery and registration.
- API Gateway: Centralized entry point to route requests to appropriate microservices.
- Spring Cloud Config: Externalized configuration management for microservices.
The following advanced REST API concepts have been implemented:
-
Custom Exception Handling: Gracefully handle errors with user-friendly messages.
-
Validation: Enforce rules for incoming requests.
-
Swagger Documentation: Comprehensive API documentation for easy consumption.
-
Jackson Dependency: Support for multiple representations (e.g., JSON, XML).
-
Versioning: Support for versioned APIs for backward compatibility.
-
HATEOAS: Hypermedia as the Engine of Application State for richer API interactions.
-
Customizing Responses:
- Serialization and field name customization.
- Selective field filtering in responses.
-
Pagination: Efficiently handle large datasets.
-
Model Mapper: Simplify data transformations.
- Spring Boot Actuator: Provides insights into the application's health, metrics, and runtime state.
CurrencyExchange ├── api-gateway ├── cloud-config ├── currency-conversion-service ├── currency-exchange-service ├── limit-service └── common-modules
- Swagger: Available for each service to explore API endpoints.
- HATEOAS: Included in API responses for navigation.
- Java: JDK 17 or later
- Spring Boot: Version 3.x
- MySQL: Ensure the database is running and accessible.
- Clone the repository.
- Set up the MySQL database and update the connection details in each service's
application.properties. - Start the Eureka Naming Server.
- Start the Spring Cloud Config Server with proper configuration.
- Start each microservice one by one.
- Access the API Gateway for testing endpoints.
Feel free to fork the repository and contribute! Contributions, issues, and feature requests are welcome.
This project is licensed under Me.
