This presentation will give information about What is Serverless? What service is exposed by AWS to support Function as a Service. Lambda is AWS service which support serverless.
4. Serverless Computing is a concept that is developed recently. A traditional back end system is deployed and ran on
a server or a group of servers. The advantage of a traditional server approach is that you have control over your
own servers and the infrastructure behind it. One of the main disadvantages is an increased cost. Not only you have
to hire DevOps or infrastructure engineers to build and maintain the infrastructure, you also pay for idle servers.
Serverless technology solves these problems. With serverless computing, you use a service that runs your code
and maintains the infrastructure behind it. You only pay for the time it takes to process each request. AWS has a
service for it called AWS Lambda, Microsoft offers similar Azure Functions, Google Cloud has Cloud Functions
Serverless is based on FaaS (Function as a service) model of cloud computing, in that it frees the user from
managing – or even considering – the underlying operating system. The user-developed functions are designed to
start quickly and run multiple instances, if necessary. The user does not see, and is not billed for, a program
listening for requests to run the functions. FaaS is referred to as a “serverless architecture” – the server is invisible,
but still there, of course.
Serverless computing is an architecture where code execution is fully managed by a cloud provider, instead of the
traditional method of developing applications and deploying them on servers.
It means developers don't have to worry about managing, provisioning and maintaining servers when deploying
code
Previously a developer would have to define how much storage and database capacity would be needed pre-
deployment, slowing the whole process down.
AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Serverless Computing
6. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Comparison of VM based, container
based and serverless application
8. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Virtual machines, container and serverless programming are run
applications but their nature are different.
Virtual machine incorporate everything including the operating system.
Container provide access to a common operating system.
Serverless systems provide a standard application interface.
Comparison Paas, Container and Serverless
10. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
No hardware/software to manage
The management of the serverless computing environment all the way
from the underlying hardware to the OS, to even the application's
platform layer, is managed by the cloud provider itself
Faster execution time
Unlike your standard cloud instances, which generally take a good
minute or two to boot up, functions, on the other hand, spin up very
quickly, mostly in a matter of seconds.
Low cost
the pricing model for serverless computing is a little different from that
of your traditional cloud pricing model. Here, you are generally billed on
the duration of your function's execution and the amount of memory it
consumed during its execution period. The duration is calculated from
the time your code begins executing until it returns or otherwise
terminates and is rounded up to the nearest 100 ms
11. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Support of popular programming language
Most cloud providers that provide serverless computing frameworks today,
support a variety of programming languages, such as Java, Node.js, Python,
and even C#. Azure functions allows the use of F#, PHP, Bash, Batch and
PowerShell scripts in addition to the few mentioned.
Micro services compatible
Since serverless computing functions are small, independent chunks of
code that are designed to perform a very specific set of roles or
activities, they can be used as a delivery medium for micro services as
well. This comes as a huge advantage as compared to hosting your
monolithic applications on the cloud, which do not scale that effectively.
Event driven applications
Serverless functions are an ideal choice for designing and running event-
driven applications that react to certain events and take some action
against them. For example, an image upload operation to a cloud
storage triggers a function that creates associated thumbnail images for
the same
13. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Three-tier Architecture Overview
The three-tier architecture is a popular pattern for user-facing applications. The tiers that
comprise this architecture include the presentation tier, the logic tier, and the data tier.
The presentation tier represents the component that users directly interact with (such as a web
page, mobile app UI, etc.).
The logic tier contains the code required to translate user actions at the presentation tier to
the functionality that drives the application’s behavior.
The data tier consists of storage media (databases, object stores, caches, file systems, etc.)
that hold the data relevant to the application
14. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
The Serverless Logic Tier
The logic tier of the three-tier architecture represents the brains of the application. This is why
integrating Amazon API Gateway and AWS Lambda to form your logic tier can be so
revolutionary.
The features of the two services allow you to build a serverless production application that is
highly available, scalable, and secure. Your application could use thousands of servers, however
by leveraging this pattern you do not have to manage a single one.
15. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Mobile Backend Architecture
Presentation Tier: A mobile application running on each user’s smartphone.
Logic Tier:
Amazon API Gateway and AWS Lambda. The logic tier is globally distributed by
the Amazon CloudFront distribution created as part of each Amazon API
Gateway API.
A set of Lambda functions can be specific to user/device identity management
and authentication, and managed by Amazon Cognito, which provides
integration with IAM for temporary user access credentials as well as with
popular third party identity providers. Other Lambda functions can define the
core business logic for your mobile back end.
Data Tier: The various data storage services can be leveraged as needed; options
are discussed earlier in this paper.
18. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
AWS Lambda is a compute service from the cloud vendor Amazon Web Services (AWS) that lets you do just this: run
code without provisioning or managing servers. Developers can focus on their code and event triggers and AWS takes
care of the rest.
You pay only for the compute time you consume - there is no charge when your code is not running.
With Lambda, you can run code for virtually any type of application or backend service - all with zero
administration.
Just upload your code and Lambda takes care of everything required to run and scale your code with high
availability
You can set up your code to automatically trigger from other AWS services or call it directly from any web or
mobile app.
Very economically pricing model. One Million request free per month for free tier account.
20. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Lambda Development Life Cycle
Write some code
Create lambda function, upload your code to the
platform
Name
Configuration
Invoke the lambda function
Platform routes event to lambda container
Platform manages container creation / lifecycle
Lambda Function
21. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Required Lambda Configuration
Runtime
Nodejs
Java 8 runtime
Python
Go
C#
Powershell
Handler
For Java, package.class::method
Memory (128 MB to 3008 MB)
Timeout (1 seconds to 15 minutes)
IAM Role
Lambda Function
22. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Lambda JVM Runtime
Java 1.8
Max heap size is 85% of Lambda memory.
Runtime includes aws-lambda-java-core
Other AWS, Java SDK are not included.
JVM parameters cannot be altered.
Timeout (1 seconds to 15 minutes)
IAM Role
24. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
What Causes Cold Starts?
Deploying a new Lambda function
Updating Lambda’s configuration
Updating Lamdba’s code
Increasing a Lambda’s concurrency (scaling)
Invoking a Lambda function after a period of inactivity
Invoking a Lambda function after the platform tears it down
25. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Lambda Container Cold Start
Platform creates a new container.
Platform installs your code (zip or JAR file).
Container instantiates the language runtime.
27. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Limitations of Lambda
Execution duration:
Serverless functions are designed to run for short durations of time, ideally
somewhere under 15 minutes only. This is a hard limit set by most cloud providers,
however, there are a few workarounds to this as well.
Stateless: Serverless functions are purely stateless, which means that once the
function completes its execution or is terminated for some reason, it won't store any
data locally on its disk.
Complexity: The smaller you make things, the more complex it's going to become.
Although writing functions that perform very particular tasks is a good idea, it can
cause complexity issues when you view your application as a whole system. A simple
example can break one large application into some ten different functions such that
each perform a specific task. Now you need to manage ten different entities rather
than just one. Imagine if you had a thousand functions instead.
28. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Limitations of Lambda
A function with 3008 MB of RAM
Invoke request body payload size: 6MB
Invoke response body payload size: 6MB
Maximum execution duration per request: 300 seconds
Lambda function deployment package size (.zip/.jar file): 50MB
Size of code/dependencies that you can zip into a deployment package
(uncompressed jar file):250MB
Total size of all the deployment packages that can be uploaded per region: 75 GB
32. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
About Technology Fusion
Technology Fusion is a venture of G Systems. It is run by a group of
professionals and focusing on training and development of students and
professionals.
Technology Fusion have experts in cloud computing, web application
development, application maintenance, application support and android
development. It's our efficient and effective solution that has given us
satisfied clients. We clearly understood and defined so that automation is
really effective and gives the right results.
Linked In : https://www.linkedin.com/company/technologyfusion/
Twitter : https://twitter.com/techfusion11
Facebook: https://www.facebook.com/Technology-Fusion-1632011516888061/
Google+ : https://plus.google.com/u/0/116172328284236227316
33. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
Technology Fusion Services
Technical training by Industry Leaders
Soft skill training by Industry Leaders
AWS Serverless Training
Deep Dive into AWS Lambda
Industrial training for BTech, M.Tech, MCA, MBA, BCA, BBA etc.
Resarch projects: For PHD students.
Live projects: Work on live projects.
AWS Certification classes for beginner and professionals
DevOps training
Azure and Google cloud training
Mobile application development training
Web application development training
Agile Training
SCRUM/ Kanban Training
Goal setting and career path workshop etc.
34. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
About G Systems
G Systems started in 2011. G Systems works on cutting edge technologies
and we have experienced team of different domain and technology. It is
running by a group of professionals.
G Systems have experts in cloud computing web application development
and maintenance with android development. It's our efficient and
effective solution that has given us domestic and global giants as satisfied
clients. We clearly understood and defined so that automation is really
effective and gives the right results.
Website: www.onlinegsystems.com
Email: info@onlinegsystems.com
35. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
G Systems Services
Cloud Consulting (AWS, Google, Azure)
Web Application Development
Mobile Application Development
Application Support
Content Writing
Search Engine Optimization
Logo Design
Branding
36. AWS Serverless Workshop
Technology Fusion | Nurturing Professionals - www.technologyfusion.in
CSR Partner
Amarpushp Educational and Welfare Society is our CSR Partner.