Re:Death by a Thousand Microservices
by corethree on Thursday September 14, 2023 @12:49AM
(#37505103)
>you mean decoupling data from code, that's not the goal. It's to decouple one team's data from another team's data
Use a schema bro.
You can do this with two schemas. Think of it as folders in databases. Then give different permissions to users per schema.
Our DBMS doesn't support schemas, but our team's services just use separate tables with separate ACLs. I think of those cliques as separate databases cause it's basically the same thing.
It can also have multiple "databases" on a single running instance, each with separate quota and ACLs. So each team uses its own database. Only a few teams are special enough to need a dedicated instance.
Also if by "decoupling data and code" you mean decoupling data from code, that's not the goal. It's to decouple one team's data from another team's data, and to properly abstract it.
The only reason our mono-DB even lasted this long was because previously, very few requirements were changing over time. So when people say their big org is monolithic, I can believe it. It works in some scenarios, in most it doesn't.