From the course: Case Study: Visualize Complex Microservice Data Using Python
What are microservices? - Python Tutorial
From the course: Case Study: Visualize Complex Microservice Data Using Python
What are microservices?
- [Instructor] Microservices are a common architecture in modern software development. They enable quick delivery of large and complex applications by breaking up the software into independent services. Each service runs its own process and it communicates with the client using lightweight protocols. Applications are built as a collection of smaller services, rather than one whole app. Before, everything lived in one monolithic application. If you think of a social network, imagine all the code regarding profile information, the social feed, discover page, login functionality, and more living in one code base. Yikes. If it all lived in one place, it would be much harder to scale because you'd have to scale the entire application, rather than just one component. What happens if one feature breaks in a deployment? It could bring down the entire application. If they were separated into independent services, then only that feature would go down. With a monolith, development also becomes harder because components and layers become more tightly coupled. Although developers might be using SOLID and OOP principles, it might become more tightly coupled just by living in the same code base. The microservices architecture seeks to resolve some of these issues. Instead of focusing on a full application, development teams can focus on specific components or services. This means instead of having one application with the profile information, social feed, discover algorithm, it would be broken up into smaller, independent services. This allows teams to concentrate on the development of their service without needing to coordinate with other teams, except for agreeing on how their components will interact. It also provides more independence, because each microservice can be built on separate servers with whatever technology that makes sense for the problem at hand, not to mention the ability to scale individual features independently and have a higher availability due to everything being less coupled. Now, monoliths did exist for a reason. Big, complex applications weren't created overnight. They took years and years of development. 20 years ago, applications were less complex, and so everything could live in the same code base and there were no problems. As applications have gotten more sophisticated, the need to break them down into separate independent services became more apparent as companies began to prioritize scaling, high availability, and component independence. I challenge you to go online and search for some examples of the microservice architecture being used at large tech companies like Amazon and Netflix. Start a discussion about what you find in the comments or in your next team meeting.