๐ Table of Contents
- ๐ Table of Contents
- ๐ Overview
- โ๏ธ Features
- ๏ฟฝ Getting Started
- ๐บ Roadmap
- ๐ค Contributing
- ๐ License
- ๐ Acknowledgments
๐ Overview
This project is an API service designed and implemented using Domain-Driven Design (DDD) principles. DDD is an approach to software development that greatly emphasizes the importance of understanding and modeling the domain. It aims to ease the creation of complex applications by connecting the related pieces of the software into an evolving model.
The API service is structured around business domains, each represented by a bounded context. The bounded context isolates the domain's models, making them specific to the context and independent from others. This isolation allows the model to evolve independently, reducing the risk of changes in one context affecting others.
The service is built with a layered architecture, typical in DDD:
- Domain Layer: This is the core of the software, containing business logic and types, which doesn't depend on other layers.
- Application Layer: This layer drives the workflow of the application, directing the domain layer, and is kept thin with logic that does not belong in the domain.
- Infrastructure Layer: This layer provides generic technical capabilities that support higher layers (message sending, persistence, drawing UI components, and so on).
- Adapter Layer (or Presentation Layer): This layer is responsible for presenting information to the user and interpreting the user's commands.
This DDD approach ensures that the focus is on the core domain and domain logic, basing complex designs on a model, and initiating a creative collaboration between technical and domain experts to iteratively refine a conceptual model that addresses particular domain problems.
The API service is designed to be scalable, maintainable, and organized around the business domain, providing a strong foundation for further development and adjustments as the understanding of the domain evolves.
โ๏ธ Features
- HTTP Support: The service can handle HTTP requests and responses.
- Behavior-Driven Development (BDD): The service is developed with a focus on behavior, making it more aligned with business requirements and easier to understand.
- Event Sourcing: The state of the business objects is determined by a sequence of events, providing a great audit trail and history that can enable various business insights.
- SQL Transactions: The service supports SQL transactions to ensure data consistency and integrity.
- Anti-Breakdown
- Anti-Penetration
- Anti-Avalanche
๐ Getting Started
๐ฆ Installation
- Clone the DDDGo repository:
git clone https://github.com/program-world-labs/DDDGo
- Change to the project directory:
cd DDDGo
- Install the dependencies:
go mod tidy
๐งช Running Tests
make test
๐บ Roadmap
โน๏ธ Role Implementation
โน๏ธ Event Sourcing Implementation
โน๏ธ User Implementation
โน๏ธ Group Implementation
โน๏ธ Wallet Implementation
๐ค Contributing
Contributions are always welcome! Please follow these steps:
- Fork the project repository. This creates a copy of the project on your account that you can modify without affecting the original project.
- Clone the forked repository to your local machine using a Git client like Git or GitHub Desktop.
- Create a new branch with a descriptive name (e.g.,
new-feature-branch
orbugfix-issue-123
).
git checkout -b new-feature-branch
- Make changes to the project's codebase.
- Commit your changes to your local branch with a clear commit message that explains the changes you've made.
git commit -m 'Implemented new feature.'
- Push your changes to your forked repository on GitHub using the following command
git push origin new-feature-branch
- Create a new pull request to the original project repository. In the pull request, describe the changes you've made and why they're necessary. The project maintainers will review your changes and provide feedback or merge them into the main branch.
๐ License
This project is licensed under the โน๏ธ INSERT-LICENSE-TYPE
License. See the LICENSE file for additional info.