During the early 2000, vendors of cloud computing had started providing open-source software and infrastructure setup to IT organizations, as hosted services on private or hybrid clouds. This framework eventually matured after standardization of cloud-computing models – Infrastructure as a Service (IaaS), Platform as a Service (PaaS), and Software as a Service (SaaS). Cloud providers also, started providing hardware and software assets as per-use service-based models. This resulted in significant reductions in the expenditure and led to serverless architecture. A serverless architecture is the method to build and run applications and services without having to manage infrastructure. Applications still run on servers, but the server management is completely owned by Cloud Platform (AWS, Azure etc.). You no longer have to provision, scale, and maintain servers to run your applications, databases, and storage systems.
Why Serverless Architecture?
Serverless architectures help developers focus on code instead of worrying much about managing servers, on cloud or on-premises.
Serverless applications have three main advantages:
- No need of allocation or server maintenance
- Auto-scaling of applications or adjusting capacity, instead of units of individual servers
- Built-in availability and fault tolerance
Why is serverless computing essential as a paradigm?
Serverless computing has evolved from micro-services to architecting applications and software. The idea behind this is to let the CSPs manage the basic compute infrastructure required and allow developers to focus only on the functionality that needs to be delivered.
Few advantages of serverless computing are:
- Suitable for event-driven scenarios: In the traditional model, scaling up or down needs time and it is not cost effective to do it continuously. This is an ideal computing model when it comes to event triggers leading to execution of small blocks of code and option to pay only for the fraction of resource times that is actually consumed.
- Build a low-cost microservices architecture: By going serverless, a lot of cloud computing functions can be executed parallelly. The smaller blocks of code are easier to manage and test. Developers can come up with an architecture mimicking micro-services by deploying several cloud functions that work together.
What does serverless architecture mean on a technical level?
Serverless computing is a process by which developers can build services from small functions. A HTTPS/HTTP request call can invoke these code blocks. The advantage could be that the billing for some of these functions need not be invoked frequently and triggered only when the need arises. This data is stored in a distinct environment that synchronizes with the active production environment.
Are there any impediments in the serverless environment?
A restriction on the measure of code is found, which when deployed supports only a couple of programming dialects. Typical code blocks and monolithic, i.e. single-tiered software application architectures should also be avoided. Another limitation is that the developers should be highly restrained in the way they are utilizing serverless computing.
What are the AWS building blocks for serverless applications?
AWS provides a set of fully managed services that you can use to build and run serverless applications. Serverless applications don’t require providing, maintaining, and operating servers for backend pieces such as compute, databases, storage, stream processing, message queuing,etc. You can also ignore application fault tolerance and availability as AWS takes care of this too. This allows you to focus on product innovation while enjoying faster time-to-market.
AWS Lambda lets you process code without provisioning or managing servers. You will be billed only for the compute time consumed, which means that there is no fee when your code is not running. All you need to do is upload your code and Lambda does the needful to run and scale your code with high availability. Lambda@Edge allows you to run Lambda functions at AWS Edge locations in response to Amazon CloudFront events.
Amazon API Gateway helps build, publish, maintain secure APIs at any scale. It allows you to churn thousands of concurrent API calls, manages traffic, provisions for authorization and access control in addition to monitoring, and API version management.
Amazon Simple Storage Service (S3) offers developers with an easy-to-use, scalable and secure object storage. All you need is a web service interface to store and retrieve any amount of data from anywhere on the web.
Amazon DynamoDB is a managed non-relational DB service that supports both document and key-value for applications that need consistent, single-digit millisecond latency at scale. AWS AppSync auto updates the data in real -time for web and mobile applications and also has offline support.
Amazon SQS is the queuing service that works with SNS for messaging and quickens decouple and scales microservices, distributed systems and serverless apps.
AWS Step Functions make it easy to coordinate the components of distributed applications and microservices using visual workflows.
Amazon Kinesis is an AWS platform for streaming data, providing services to make it easy to load and analyze streaming data. Amazon Athena is a user-friendly query service that eases data analysis in S3 using standard SQL and pay for only the queries that you run.
AWS provides tools and services for continuous integration and delivery, testing, deployments, monitoring and diagnostics, SDKs and frameworks.
Serverless computing is still relatively new to the technology space and is still evolving. It helps organizations save a significant amount of time, money and resources as it hosts, runs and manages applications and lets developers focus on the mainstream application logic.
Nandita Menon, Managing Consultant, Digital Business Consulting, RapidValue