3 ms·
It's just a matter of incentives and how hard it is to do the right thing, or hard it is to do the wrong thing. If you gap services or microservices by a Git r
by kodah 4y ago
It's just a matter of incentives and how hard it is to do the right thing, or hard it is to do the wrong thing.
If you gap services or microservices by a Git repository, then it makes it harder for them to import each other's code; you also will probably have code duplication. If you have repositories for the shared code that's safe then you have new overhead problems. If you keep them in a monorepo then it's just as tempting as in a monolith to cross domains; the only inhibition is resistance to ease of access and the only way to catch it is in code review.
These are all tradeoffs. Fwiw, I still run a monolith project, and part of code review is checking imports, and part of our documentation talks about shared code standards and locations. It can be done, there's just no natural guard rails present.