iluwatar / java-design-patterns

Design patterns implemented in Java
https://java-design-patterns.com
Other
88.27k stars 26.19k forks source link

Microservice pattern: Shared database #2667

Open iluwatar opened 8 months ago

iluwatar commented 8 months ago

Description: The Microservices - Shared Database design pattern involves multiple microservices sharing a single database schema. This pattern can be used to manage distributed data transactions and maintain data consistency across different microservices.

Main elements of the pattern:

References:

  1. Project Contribution Guidelines
  2. Microservices Architecture Patterns - Microservices.io
  3. "Building Microservices" by Sam Newman
  4. Martin Fowler's Blog on Microservices
  5. Spring Cloud Documentation

Acceptance Criteria:

  1. Create a new package for the Microservices - Shared Database design pattern within the project.
  2. Implement a working example demonstrating the shared database pattern with at least two microservices.
  3. Ensure that the example includes:
    • A shared database schema
    • Transaction management across microservices
    • Data consistency mechanisms
  4. Include unit tests and integration tests to validate the functionality.
  5. Provide comprehensive documentation explaining the implementation, including code comments and a README file in the package.
  6. Ensure the implementation adheres to the project's contribution guidelines and coding standards.
nuxchristopher commented 8 months ago

Hi @iluwatar, I have some initial thoughts on this issue, could you assign this one to me?

stale[bot] commented 6 months ago

This issue has been automatically marked as stale because it has not had recent activity. The issue will be unassigned if no further activity occurs. Thank you for your contributions.