Serverless computing: What is it and why is it important?
A quick background
The general concept of serverless computing was introduced to the market by Amazon Web Services (AWS) around 2014 with the release of AWS Lambda. As we know, cloud computing has made it possible for users to manage virtual computers and services, but customers still have to be proficient with provisioning and managing compute resources.
AWS decided to take another step in making cloud computing easier and more accessible by managing the underlying compute layer (or abstracting the infrastructure layer as you might hear it said). In the case of AWS, Lambda runs a code function without requiring you to provision the virtual machine and the operating system that runs that code.
In this article, we’ll cover the basic functions of serverless computing. To deep-dive into this topic and learn how to build, deploy, and manage the Serverless framework, check out Cloud Academy’s Serverless Training Library. With Learning Paths, Courses, Quizzes, Exams, and Hands-on Labs, you’ll gain the technical knowledge and practical experience that you need to integrate serverless architecture into your cloud IT environment.
Why is serverless computing important?
Let’s clear something up first: There is still a server involved in the serverless model, but the cloud provider manages that resource, not you, so serverless computing can possibly be better described as Functions-as-a-Service. Serverless computing is a bit like a car rental service. You just want a vehicle to get you to your destination, whether that is just across town or across the country. It is expected you will drive carefully when using the vehicle, and you will report any damage. But you are not expected to pay for the car to be built or delivered to the pickup facility first before you use it, and you are not expected to contribute to the cost of buying or preparing the car. You only pay for the time that we use the service.
The second thing to bear in mind with serverless computing — and this is the main benefit — is the effect of all the managing that the cloud provider does for you, namely, you have more time to work on developing and delivering the application!
To summarize, you get these advantages from serverless computing:
- Less worry — you don’t have to provision or manage the server
- Scalability — can handle any workloads so your work remains viable
- Cost — costs can stay under control as you cannot overprovision
General info on AWS Lambda and Google Cloud Functions
Amazon was first to market with serverless functions through their Lambda offering in 2014, and as such has been at the forefront of development. Google Cloud Functions was launched to beta in 2017 and to general availability in 2018. Google’s offering was about four years behind but has managed to catch up in many ways.
Lambda can be used in conjunction with other like services on AWS such as:
- Serverless Application Model (SAM) — an open-source framework for building serverless applications
- Serverless Application Repository — a managed repository for serverless applications
- Cloud9 — an integrated development environment (IDE) for writing, running, and debugging code
Google is part of a larger family of serverless offerings which include:
- Cloud Functions — serverless code
- App Engine — serverless application development platform
- Cloud Run — stateless containers
It’s good to remember that in general, both Lambda and Cloud Functions have been designed to play nicely with tons of other services, as long as they’re in the same provider ecosystem.
Practical Applications of Google Cloud Functions and AWS Lambda
Here are a couple of real-world examples of serverless computing, whether they’re implemented on Google Cloud Functions or Amazon Lambda:
- Realtime stream processing — gather data without setting up infrastructure or logging. This can be event-driven so that it the functions work whether you have a few requests per day or thousands per second.
- Connecting to third party applications/hardware — you can use serverless functions as lightweight integrations to other applications automate certain tasks within your cloud environment.
You can get more detailed and concrete insight and (importantly) hands-on practice by testing out Cloud Academy’s Hands-on Labs for Google Cloud Functions and AWS Lambda.
In the Cloud Functions Hands-on Lab, you can:
- Learn basic tenets of serverless architecture
- Create functions from the GCP console
- Test your skills against a subject matter expert’s real-world tasks
You can also try out our Intro to AWS Lambda Hands-on Lab guides you through building functions with Node.js.
Google Cloud Functions and AWS Lambda Features
|Functionality||AWS Lambda||Google Cloud Functions|
|Scalability & availability||Automatic scaling (transparent)||Automatic scaling|
|Max. # of functions||Unlimited functions||1000 functions per project|
|Concurrent executions||1000 parallel executions per account per region||1000 parallel executions (per function, for background functions)|
|Max. execution time||900 seconds (15 minutes)||540 seconds (9 minutes)|
|Supported Languages||Java, Go, PowerShell, Node.js, C#, Python, and Ruby code, and a Runtime API which allows you to use any additional programming languages to author your functions||Node.js, Python, Go|
|Deployments||.zip or .jar file consisting of your code and any dependencies||ZIP upload, Cloud Storage, or Cloud Source Repositories|
|Versioning||Versions and aliases||Cloud Source branch/tag|
|Event-driven||Event Sources (S3, SNS, SES, DynamoDB, Kinesis, CloudWatch)||Cloud Pub/Sub or Cloud Storage Object Change Notifications|
|HTTP(S) invocation||API Gateway||HTTP trigger|
|Logging||CloudWatch Logs||Stackdriver Logging|
|Monitoring||CloudWatch and X-Ray||Stackdriver Monitoring|
|In-browser code editor||Only if you don’t have dependencies||Only with Cloud Source Repositories|
|Granular IAM||IAM roles||IAM roles|
|Pricing||1M requests for free, then $0.20/1M requests, plus $0.00001667/GB-sec||2M requests for free, then $0.40/1M invocations, plus $0.0000025/GB-sec|
Serverless functions are a great way to leverage the elasticity of cloud deployments. Make sure to consider the big picture in your environment, such as your medium- to long-term plans and how you want to maintain code that you create for serverless architecture.
You can get further detailed guidance on serverless architecture by checking out our huge catalog of Learning Paths, Courses, Quizzes, Exams, and Hands-on Labs.
New Content: Platforms, Programming, and DevOps – Something for Everyone
This month our team of expert certification specialists released three new or updated learning paths, 16 courses, 13 hands-on labs, and four lab challenges! New content on Cloud Academy You can always visit our Content Roadmap to see what’s just released as well as what’s coming soon....
Mastering AWS Organizations Service Control Policies
Service Control Policies (SCPs) are IAM-like policies to manage permissions in AWS Organizations. SCPs restrict the actions allowed for accounts within the organization making each one of them compliant with your guidelines. SCPs are not meant to grant permissions; you should consider ...
New Content: Focus on DevOps and Programming Content this Month
This month our team of expert certification specialists released 12 new or updated learning paths, 15 courses, 25 hands-on labs, and four lab challenges! New content on Cloud Academy You can always visit our Content Roadmap to see what’s just released as well as what’s coming soon. Ja...
New Content: Get Ready for the CISM Cert Exam & Learn About Alibaba, Plus All the AWS, GCP, and Azure Courses You Know You Can Count On
This month our team of intrepid certification specialists released five learning paths, seven courses, 19 hands-on labs, and three lab challenges! One particularly interesting new learning path is Certified Information Security Manager (CISM) Foundations. After completing this learn...
Which Certifications Should I Get?
The old AWS slogan, “Cloud is the new normal” is indeed a reality today. Really, cloud has been the new normal for a while now and getting credentials has become an increasingly effective way to quickly showcase your abilities to recruiters and companies. With all that in mind, the s...
The 12 AWS Certifications: Which is Right for You and Your Team?
As companies increasingly shift workloads to the public cloud, cloud computing has moved from a nice-to-have to a core competency in the enterprise. This shift requires a new set of skills to design, deploy, and manage applications in cloud computing. As the market leader and most ma...
AWS Certified Solutions Architect Associate: A Study Guide
Want to take a really impactful step in your technical career? Explore the AWS Solutions Architect Associate certificate. Its new version (SAA-C02) was released on March 23, 2020. The AWS Solutions Architect - Associate Certification (or Sol Arch Associate for short) offers some ...
New Content: AWS Terraform, Java Programming Lab Challenges, Azure DP-900 & DP-300 Certification Exam Prep, Plus Plenty More Amazon, Google, Microsoft, and Big Data Courses
This month our Content Team continues building the catalog of courses for everyone learning about AWS, GCP, and Microsoft Azure. In addition, this month’s updates include several Java programming lab challenges and a couple of courses on big data. In total, we released five new learning...
Where Should You Be Focusing Your AWS Security Efforts?
Another day, another re:Invent session! This time I listened to Stephen Schmidt’s session, “AWS Security: Where we've been, where we're going.” Amongst covering the highlights of AWS security during 2020, a number of newly added AWS features/services were discussed, including: AWS Audit...
AWS re:Invent: 2020 Keynote Top Highlights and More
We’ve gotten through the first five days of the special all-virtual 2020 edition of AWS re:Invent. It’s always a really exciting time for practitioners in the field to see what features and services AWS has cooked up for the year ahead. This year’s conference is a marathon and not a...
WARNING: Great Cloud Content Ahead
At Cloud Academy, content is at the heart of what we do. We work with the world’s leading cloud and operations teams to develop video courses and learning paths that accelerate teams and drive digital transformation. First and foremost, we listen to our customers’ needs and we stay ahea...
Excelling in AWS, Azure, and Beyond – How Danut Prisacaru Prepares for the Future
Meet Danut Prisacaru. Danut has been a Software Architect for the past 10 years and has been involved in Software Engineering for 30 years. He’s passionate about software and learning, and jokes that coding is basically the only thing he can do well (!). We think his enthusiasm shines t...