-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question: Querying across services, Database-per-service or One database #28
Comments
Might be helpful (from microservices.io) There are various patterns/solutions for implementing transactions and queries that span services:
https://microservices.io/patterns/data/shared-database.html The benefits of Shared Database pattern are:
The drawbacks of Shared Database pattern are:
https://microservices.io/patterns/data/database-per-service.html Using a database per service has the following benefits:
Using a database per service has the following drawbacks:
|
Hi am building a simular project, using event driven microservices architecture, and am stuck thinking wether i should use a single Database and connect all services to it, or do a database-per-service approach, i could brainstorm some reasons why doing a single database is bad (sharing Model schema between multiple services)
but the advantage am looking for in the single Database approach is: you can query any table you want, which is a thing i can't do in database per service, soo my question is how would you go about querying data from another service, let's say UserManagement needs data from ticketing service for exemple, any approach aside synchronously calling the other service using http.
Am using rabbitmq to broadcast the creation of a document to other conserned services
The text was updated successfully, but these errors were encountered: