Why do you need to move on to Serverless?

Serverless has been gaining more and more traction over the last few years, and people are moving on to serverless more frequently. In the beginning of 2017 the serverless architecture market was valued at USD 3.20 billion and, with an expected Annual Growth Rate (CAGR) of 23.83%, is expected to reach USD 9.16 billion by the end of 2023. The time has already come for companies to decouple their current monolithic architectures and move on to serverless architecture.

There are many cloud service providers today such as Amazon Web Services, Google Cloud Platform, Microsoft Azure, and IBM Cloud. I have chosen AWS as the example throughout this article. So let’s take a quick look at why you need to consider moving on to serverless.

1. Less maintenance

This is one of the major benefits of serverless architecture. As the Serverless name suggests, there are no physical servers to maintain. No physical servers? Is it possible to develop an enterprise level application without them? Well not exactly, of course you require physical servers at some point; but cloud service providers are there for you, to encapsulate complexity of the server maintenance.

2. Scalability

Scalability is one of the main roadblocks for fast-growing companies, introducing a lot of issues during the process of provisioning service infrastructure and resulting in increasingly higher costs. Vertical and Horizontal scaling is not an easy task and requires a lot of effort and time, increasing overall business cost. Serverless environments remove those limitations, allowing you to start small and support the growth of your business over time without any interruption in your business flow or expensive, unplanned changes.

3. Pay as you go

Serverless architecture greatly reduces the initial capital requirement for setting up basic service infrastructure. Also it will reduce the additional cost of maintenance and scaling your own servers.

Amazon Web Services pay-as-you-go pricing model reduces the overhead of overcommitting budgets and allows customers to easily adapt to changing business needs, improving your responsiveness to changes.

AWS Lambda, a computing service provided by Amazon Web Services that lets you run code without provisioning or managing servers, allows you to pay only for the compute time you consume. In other words you are charged only for the number of requests for your functions and the resource usage during each invocation.

4. Durability

Durability of resources is one of the most important aspects of any business. When compared with local data centers, cloud service providers offer high durability for your resources in most scenarios.

Amazon Simple Storage Service or S3, is one of the most popular cloud storage services, which scales your storage resources up and down to meet fluctuating demands, without resource procurement cycles or upfront investments.

According to AWS, Amazon S3 is designed for 99.999999999% (eleven 9’s) of data durability because it automatically creates and stores copies of all S3 objects across multiple systems. This means S3 will make sure your data is available when needed, and protected against failures, errors, and threats.

5. High Availability

Today’s businesses are highly coupled with IT; every part of the business nowadays depends on some other services, provided by external service providers or on your own subsystems. So it is very important that those services guarantee high availability for their users.

Amazon Web Services has a well-designed global infrastructure providing high availability and resiliency for customer workloads. Regions, Availability Zones, Services and the Amazon control plane are the key components of this architecture.

Source: Amazon Web Services

Regions: Regions are the geographical areas in which Amazon provides cloud services. There are 21 geographical regions at the moment. You can find more about AWS regions from here.

Availability Zones: An Availability Zone is a cluster of complete, localized infrastructure in a Region. Amazon currently operates 66 availability zones globally. Every availability zone encompasses multiple data centers, typically three, in the same location. In each region, availability zones are separated by a meaningful distance, but no more than 100 km, to allow for fast connectivity between them.

6. Distributed Backend

One of the most interesting features of cloud computing is that it supports distributed architecture, enabling loose coupling between individual components. Cloud service providers, specially AWS, provide services for customers covering a wide range of technical requirements. All you have to do is choose the correct services that satisfy business requirements, and design a cloud based solution following best practices.

Here is an architecture diagram of a simple web service for user registration.

7. Rich Language Support

In traditional backend development, most of the time, developers choose one language to develop in – and stick to it. Later, even if there are new/other languages more suitable to fulfil changing requirements, it is not an easy task to switch or support multiple languages in traditional monolithic architecture.

However, in serverless all components are distributed, with very loose coupling among those components. So we can use the most suitable programming language for each individual component without interrupting existing components.

Now we are coming back to AWS Lambda again. Previously we discussed how Lambda can be cost effective with the pay-as-you-go pricing model. Now let’s take a quick look at how Lambda can be used to implement a multi-language backend.

AWS Lambda supports multiple runtimes including NodeJS, Java, Python, Go, and so forth. You can find all the languages supported by Lambda from here.

Assume there is a new requirement to collect user statistics based on their recent order details. Based on the requirement, Python will be the most suitable language for such data analytics tasks. With serverless architecture we can add a new Lambda function with Python runtime easily without affecting any other component.

8. Reduces Configuration Overhead

Development environment set-up and configuration overhead of the serverless architecture is relatively low compared to traditional monolithic applications. This will save development time and allow developers to concentrate more on business logic rather than environment setup.

9. Easy and Efficient Deployments

Most of the time, non-serverless, traditional service environments are not easy to deploy. Overhead of deploying individual components is high enough such that the overall deployment process may take several hours to complete. But, with the serverless architecture, the deployment process becomes easier and more efficient as almost every cloud service provider offers dedicated services to manage deployment processes.

AWS CloudFormation is a service offered by Amazon Web Services to manage AWS services as well as third party resources easily. CloudFormation provides a common language to model and provision AWS and third party application resources in cloud environments.

With CloudFormation you can model your entire architecture in a few JSON or YAML files and deploy it with a few simple clicks.

10. Disaster Recovery

There are a lot of events that can cause outages in IT based businesses such as unexpected infrastructure or application outages caused by flooding, earthquakes, fires, hardware failures, or even malicious attacks – and impact business continuity. So it is very important to have a disaster recovery plan (DRP) that delineates how an organization will respond to any disaster scenario, without breaking time-sensitive business processes and functions, and recovering full business continuity. Let’s explore how serverless architecture could be compliant with standard disaster recovery processes.

Amazon Web Services CloudEndure Disaster Recovery provides automated disaster recovery, eliminating manual processing overhead. CloudEndure lets you recover your environment from application outages, data corruption, ransomware, and unexpected infrastructure or other malicious attacks.