7 ms·
Microservices is a team organization technique, whereby disparate teams only communicate by well defined APIs. Any technology choices that come out of that are
by randomdata 4y ago
Microservices is a team organization technique, whereby disparate teams only communicate by well defined APIs. Any technology choices that come out of that are merely the result of Conway's Law.
Any time you lean on code in a random GitHub repository, where you never speak to the author and just use the API you're given, you're doing microservices. This works well enough so long as the product does what you need of it.
The problem is that when the product doesn't do what you need. If the microservices teams are under the same organization umbrella there is a strong inclination to start talking to other teams instead of building what's needed in house, which violates the only communicate by well defined APIs. This is where the ball of mud enters.
If your organization is such that you can call up someone on another team, you don't need microservices. They're for places so big that it is impossible to keep track of who is who and your coworkers may as well be some random GitHub repository.
- JAlexoid 4y agoNo. That's not what microservices means. You're intentionally equating all services to microservices, which is not the case. This substitution is what is commonly known as a Strawman argument. You misrepresented an argument, to discredit it easier.
- randomdata 4y ago> That's not what microservices means. You're intentionally equating all services to microservices, which is not the case. Eventually everyone provides a service to someone, I guess, but there is a clear division between those who serve end users and those who serve the servers. The service that places your food down on the table at the restaurant is not thought of in the same was as those who get to the food to the restaurant. The latter camp is often known as a supplier, but we in tech call them a microservice instead. There is no suggestion that all services are microservices.
- JAlexoid 4y agoMicroservices is defined to be extreme decomposition, which is not the same as a service. And the biggest pitfall of microservice architecture, is the creep of loose coupling. Right now I work in an environment, where user account information is copied to every single microservice's internal DB... to minimize access time to that information... Restaurant provides you with a service - one single interface. Imagine if a restaurant used a microservice architecture? You'd be spending your time going from the fridge to the cooks, moving your food from one to another(because no cook will do the whole recipe), then going to the dish storage, having a separate cook arrange your food on your plate, etc.
- randomdata 4y ago> where user account information is copied to every single microservice's internal DB... to minimize access time to that information... In terms of access time, what does that gain you over a bog standard shared database? With careful planning, you can likely achieve the lowest access times using a shared database. There is so much more room for optimization at every level. The reason actual microservices (teams only communicating via API contracts) must carry out this practice of duplicating data is because a shared database requires non-API communication for various things, like enabling schema changes. If you can call up someone on another team to talk about how to upgrade the database and reach a shared understanding, what do you need API-only communication for? Did your organization become confused about why they are doing that and then invented a performance argument to justify it?
- JAlexoid 4y agoYou're not allowed to have a share DB with microservice architecture. Every microservice is completely self contained... The architecture of my organization was created by ardent microservice advocates, that took the definition of a microservice and treated it like a bible. Based on the conversations I had here, there are still people that treat microservices as sacrosanct. The more I work with microservices, the more I'm convinced that microservice first architecture is garbage. The copying of the data is the solution to data access latency.
- nxpnsv 4y agoThey can be that, but that is not what they are.
- dmak 4y ago> Any time you lean on code in a random GitHub repository, where you never speak to the author and just use the API you're given, you're doing microservices. This works well enough so long as the product does what you need of it. No. That's not what a microservice is. I understand you are trying to draw analogies, but a library is not a considered a microservice.
- randomdata 4y ago> a library is not a considered a microservice. Quite right. As before, people provide service. A library is something that people can produce as part of their service, perhaps, but a library is not a person itself.
- gryn 4y agoSo using your definition what is the difference between a module, a service, and a microservice ?
- mozey 4y agoModules are for organising your code, services are for organising processes on the OS, and micro-services are for organising teams of developers
- mirekrusin 4y agoYou can organize teams of developers around services.
- deleted 4y ago[deleted]
- randomdata 4y agoDevelopers all provide the same service (more or less), giving no clear delineation in which to organize. More likely will you organize teams of developers around products.
- manojlds 4y agoMicroservice are a way to organize teams. Modules and services also serve that purpose.
- randomdata 4y agoA service is something someone provides. A microservice is much the same, but serves those who offer services to the end user – roughly analogous to a supplier in the physical goods space. A module may be the product of the service rendered.
- quonn 4y ago> Any time you lean on code in a random GitHub repository, where you never speak to the author and just use the API you're given, you're doing microservices. So a library is a microservice now?
- JAlexoid 4y agoEverything is a microservice, even Linux kernel modules are... apparently. And also - nothing is a microservice, because it's not separated strongly enough.
- actionfromafar 4y agoZen Enlightenment? I think you put it very well, actually. Software development is so much about culture and understanding.
- randomdata 4y ago> Everything is a microservice, even Linux kernel modules are... apparently. A microservice is comprised of people. Not a whole lot different than a service, but narrower in what is offered such that the service doesn't provide something useful on its own and is meant to be integrated with other services to achieve its full utility, hence the 'micro' moniker. In the world of physical products we often call these people suppliers. It is possible that a microservice may produce Linux kernel modules.
- mwhitfield 4y agoSure, I guess if you completely redefine the word "microservice" to something completely different from the common understanding, it makes more sense. If someone is writing about "microservices," they are generally talking about the situation where those APIs and team boundaries are exclusively (or at least primarily) composed of separate applications communicating over the network. Not what you're talking about.
- randomdata 4y ago