choreo
2022/05/12

Why Should You Have a Microservices Management Platform? - Part 1

  • By Hasitha Abeykoon
  • 12 May, 2022

Photo by Mike Hindle on Unsplash

Introduction

Digital transformation is crucial for organizations as more industries continue to find the benefits of leveraging technology. According to Markets and Markets, the digital transformation industry will grow from $521.5 billion in 2021 to $127.5 billion in 2026. To gain a competitive edge, eventually all companies will need to adopt software that helps them improve. Banking, transport, and healthcare services moved towards digitalization a few years back. Following the COVID-19 pandemic, organizations across industries around the world are working to provide their services digitally as the shift to online services becomes more significant.

Accelerating Digitalization 

To gain value from digitalization, companies must speed up the process of building and deploying software. Simultaneously, they must remember their organization could grow, or change over time. As such, their software platforms should be extensible to absorb these changes. Building applications from scratch requires a great deal of time, money, and effort. It is also more error prone. Hence, companies should consider using platforms that provide underlying capabilities and focus their efforts to build their business-specific applications. 

The first step of online platforms was bought by Infrastructure-as-a-services (IaaS) providers such as Amazon (Amazon Web Services), Google (Google Cloud Platform) and others which enabled users to focus on writing applications without worrying about building their own infrastructure and data centers, deployment aspects, managing data, network security, disaster recovery etc. Simply put, they provided virtual infrastructure where users could run their software. 

The next step of providing platforms was Platform-as-a-service (PaaS). Here, Heroku, Oracle Cloud Platform (OCP), Google App Engine, Microsoft Azure, Amazon Web Services, and Elastic Beanstalk were quite popular. A PaaS provides surrounding tools to build and run your software better. They provided databases, middleware, operating systems, analytics, and connectivity to third-party applications. 

On top of PaaS platforms, developers could build software and allow users to access them as a service. This packaged software could be accessed online and became known as Software-as-a-Service (SaaS). Here, users do not need to install native software on their machines, but access software through a lightweight web browser over internet technologies and protocols. This mechanism eliminated the need for edge computing devices to have large CPUs and memory to run software. 

In the journey of moving in-house infrastructure to the cloud, a few variants of cloud computing came into existence. Hybrid cloud computing is one of them, where on-premise systems and cloud platforms work in harmony to deliver end user requirements. Oracle explained cloud computing in 2014, which has since grown in popularity.

What are Microservices and why do you Need Them?

While advancements in cloud computing were taking place, companies also needed to find better ways to manage software development. Usually, an integrated set of applications would be built by different development teams working parallelly. Various applications could be built with different technologies and protocols. These applications would have different goals and provide varying functionalities to the integrated system. Furthermore, there could be dependencies between them. Ultimately, they would provide an integrated digital experience.

DZone refers to microservices, as an “architectural style that structures an application as a collection of small autonomous services, modeled around a business domain.” The main idea of microservices architecture patterns were to componentize the application based on services and to develop, deploy, and manage them separately. These components/services communicate using either synchronous protocols such as HyperText Transfer Protocol (HTTP), Representational state transfer (REST) or asynchronous protocols such as Advanced Message Queuing Protocol (AMQP). The services can be developed and deployed independent of one another. 

Martin Fowler describes the main characteristics of a microservice architecture as follows: 

  • Componentization via services
  • Organized around business capabilities
  • Products not projects
  • Smart endpoints and dumb pipes
  • Decentralized governance
  • Decentralized data management
  • Infrastructure automation (CI/CD)
  • Design for failure

Through these characteristics, microservices architecture solves key issues companies have while building and running software in their digitalization journey. Some reasons for the accelerated growth in adopting this architecture can be summarized as follows. 

  • Increased resilience - when a code segment fails it does not affect multiple components, causing minimal impact.
  • Improved scalability - as each service is a separate component, each component can be scaled independently without scaling the entire application. 
  • Using the right tool for the right task - developers can choose libraries, language, and protocols to develop each service. The entire application is not bound to a single vendor.
  • Faster go to market - when the business changes, developers do not need to update all application components. By developing applications in smaller increments that are independently testable and deployable, companies get applications and services to market faster.
  • Easier maintenance - as services are modeled as loosely coupled smaller components, debugging and testing is easier. 
  • Make use of continuous delivery - microservices use cross-functional teams to handle the entire lifecycle of an application using a continuous delivery model. With the incremental development approach, applications are continuously developed, tested, and deployed. 

Without a doubt, API centric design principles and REST models in HTTP protocols are helpful when implementing microservices. Each service exchanges data with other services through well-defined interfaces. This makes microservices independent and decoupled from each other, yet cohesive. Developers in several teams developing various microservices know how to pass and retrieve data from other services.

Although it yields several benefits, adoption of microservices needs to be done with care. 

Challenges with the Microservices Approach

A survey by O’Reilly on success rates when adopting microservices reveals that 54% of respondents describe their use as “mostly successful”. Nonetheless, adopting microservices is not straightforward. This is due to several challenges which result in moving from a traditional VM based architecture. These are outlined below:

  • Services and components are smaller when designed as microservices. There are several services and components in the system. To deliver a useful feature, at least two of them must get connected. Developers must implement the inter-service communication mechanism and deal with partial failure. Designs must be done with failure in mind. 
  • As components are smaller, development teams can produce more changes and new features. They will need to deploy these features to production more frequently to maintain continuous innovation. 
  • Infrastructure components like containers and load balancers will increase in number and must be managed. 
  • Infrastructure components can change dynamically due to auto healing and dynamic scaling, leading to increased complexity. 
  • Testing and debugging microservices is not easy. Implementing and testing requests that span multiple services is more difficult. 
  • Implementing requests that span multiple services requires careful coordination between teams.
  • With simple microservices in place, it can be difficult to see the bigger picture with the overall system. This can lead to problems with observability, making it difficult to make managerial and technical decisions. 
  • Microservices can increase questions related to security of the platform due to increased complexity and intercommunication between components. 
  • Teams may need to learn new technologies such as containers, Docker, and Kubernetes. 
  • Microservices increases the number of configuration points across multiple dimensions, possibly leading to an increase in misconfigurations during deployments. 

As you can see, adopting microservices without proper planning can be a nightmare. The traditional approach of product development and release management will not avoid these pitfalls. The following points illustrate what can take place if these issues are left unaddressed and what kind of solutions developers need to overcome these challenges.

  • Deployments: Traditionally, when a new feature or a bug fix is introduced to a software component, the feature is rebuilt, tested, and deployed to a static VM replacing the previous version of the software. However, with a microservices approach, several components will run on different containers. Depending on them individually is not scalable, causing the system to become unstable. We need an automated way of performing deployments with the right configurations. 
  • Configuration of secrets and endpoints: For a monolithic application, endpoints, secrets, and other configurations are manually injected before starting the application. However, in the event of many individual components and endpoints which vary dynamically, the above approach does not work. There must be a way to dynamically configure those with dynamic values which we can extract from the system itself. 
  • Failure, recovery, and scalability: In a traditional application, when a production incident occurs, the production support team will observe the logs, identify the problem, create a hotfix, and redeploy the application. When there are a set of microservices working together to serve a request, identifying, and fixing the correct issue is more complex, time consuming, and may also involve different team collaborations. 

In the journey of enterprise digitalization, moving from on-premise VMs to cloud is a critical step. Most companies tend to choose an iPaaS solution and deploy their existing applications as they are, which is not suitable. In our next article, we will review how a microservices management platform can help organizations to overcome these challenges, their benefits, and their existing platforms. 

Table of Contents

WSO2 for Startups

Launch Your Projects Quickly with Our SaaS Products at No Starting Cost

Apply Now

Get Updates on Choreo

Follow us

Learn About Security At WSO2