Backend technology is constantly evolving as user demands shift and the mobile landscape advances. We once relied on tools like PaaS and IaaS, which led to the birth of APIs, MBaaS and API management. Now, the development community is turning towards microservices to tackle backend development and create apps that can connect with the larger mobile landscape.
The term has been thrown around a lot lately. Chances are you’ve heard people talk about the benefits of microservices, but the architecture is still fairly new. Here are five things you need to know:
What Are They?
The term microservices distinguishes an architectural pattern that promotes development of relatively small services with narrowly-focused interfaces that can be independently deployed, scaled and updated.
Microservices emphasize an alternative approach to classic monolithic architecture and service-oriented architecture (SOA), which generally tend to involve heavier tooling and processes and greater coordination and integration efforts that all add developer friction.
Advancements in containerization technology have fueled the rise and popularity of microservices. Today microservices presume some form of containerization, such as the wildly popular Docker, which has exploded into prominence since 2013.
What’s Driving the Movement?
A key driver in the movement toward microservices is the proliferation of connected devices — smartphones, tablets, wearables, smart home appliances, fitness trackers, drones and beyond. With connected devices flooding the market, there’s an increased emphasis on APIs. We once advocated a “mobile-first” approach to app development, but the extent of connected experiences now demands an “API-first” mentality in which there is a common API tier to render data in the right size and format for any device.
Modern consumers and even business customers expect feature updates on much more rapid iteration cycles than what historically existed for classic software applications, but larger applications take longer to build, test and release. Microservice architecture is an approach toward building, deploying, scaling, and evolving individual services in cycles that are much more responsive to market requirements.
What’s the Difference Between Microservices and SOA (Service-Oriented Architecture)?
Microservices and SOA share several similarities, but ultimately involve different patterns for development. Microservices offer the efficiency of reusable functionality over a network like SOA, but generally tend to dispense with the complexity of classic SOA and Web services specifications. What’s more, microservices do not rely on middleware ESBs (enterprise service buses), a model for a communication backbone between mutually interacting applications among corporations.
What are some of the benefits?
Microservices promise scalability and flexibility, so developers can create cohesive, connected experiences across devices. Here’s how:
Services Are Partitioned Along Functional Boundaries
Microservices allow developers to build smaller, more focused services, which are physically partitioned along functional boundaries. This boosts productivity and quality because services can evolve and be deployed and scaled independently using smaller development teams dealing with less complicated codebases. An application with a large codebase and extensive surface area that involves a team of thirty is less likely to go through a test and deployment pipeline just to update a single feature update than a microservice involving a team of three.
Each Service Can Use It’s Own Language
Since microservice communication happens over a network between separate processes, they also allow developers to implement each service with the language, frameworks and ancillary services that make the most sense for the associated operation. For example, a service for a statistical operation could be built in Python, while a service performing a basic operation could be implemented in an entirely different language. While this approach would historically have been challenging to manage operationally, container technology today makes this approach entirely pragmatic.
What are some of the drawbacks?
While microservices reduce developer friction, shorten release cycles and provide the potential for far more cost-effective scalability in production, this pattern does come with challenges. Having more services means managing more pipelines to production, which will have an impact on devops and realistically means making a firm commitment to automation. There will be an increased burden on monitoring, so a unified and centralized approach to monitoring and logging will be vital.
Finally, distributed computing presents challenges that developers of monolithic applications may not be accustomed to, such as service orchestration.
The industry is moving fast in this area and the newest version of Docker now makes service orchestration part of the core platform, but your team’s skills will need to adapt. With the developer community embracing microservices, you can expect public and enterprise cloud providers to provide evolving solutions that ease the operational challenges around orchestration, management and monitoring.