Share
Embed
What Can You Do with Serverless ...in 2020?
ServerlessDays, Belfast, January 24th, 2020
Danilo Poccia
January 24, 2020
Transcript
55 slides
-
© 2020, Amazon Web Services, Inc. or its Affiliates. Danilo
Poccia Principal Evangelist, Serverless @danilop What Can You Do with Serverless …in 2020 ? -
© 2020, Amazon Web Services, Inc. or its Affiliates. How
does Serverless work? Storage Databases Analytics Machine Learning . . . Your unique business logic User uploads a picture Customer data updated Anomaly detected API call . . . Fully-managed services Events Functions -
© 2020, Amazon Web Services, Inc. or its Affiliates. Serverless
in December 2014… and the first half of 2015 Thumbnails Generators! S3 Bucket Lambda Function S3 Bucket -
© 2020, Amazon Web Services, Inc. or its Affiliates. Serverless
in the first half of 2015 Static Content Generators! S3 Bucket Lambda Function S3 Bucket -
© 2020, Amazon Web Services, Inc. or its Affiliates. Serverless
in the first half of 2015 Dynamic Websites & Apps! Browser JavaScript DynamoDB Table S3 Bucket Lambda Function AWS SDK Lambda Invoke -
© 2020, Amazon Web Services, Inc. or its Affiliates. Serverless
in the second half of 2015… and later on! APIs! ”Alexa!” & IoT Microservices DevOps Browser Web APIs Amazon Echo IoT Devices Services Data Streams DynamoDB Table S3 Bucket Lambda Function API Gateway Schedule -
© 2020, Amazon Web Services, Inc. or its Affiliates. Over
the years, customers shared some concerns… New Paradigm Scalability Costs Latency Language Support -
© 2020, Amazon Web Services, Inc. or its Affiliates. Observability
Configuration Management Function Invocations Execution Environment Service Integrations So what have we been focusing on? -
© 2020, Amazon Web Services, Inc. or its Affiliates. Latency
Observability Configuration Management Function Invocations Execution Environment Service Integrations Language Support Costs Scalability New Paradigm -
© 2020, Amazon Web Services, Inc. or its Affiliates. Function
Invocations AWS Lambda Asynchronous Invocations (Event) Max event age Max retry attempt Destinations (to Lambda, SNS, SQS, EventBridge) ⇣ More controls for async and event-driven apps Scalability New Paradigm -
© 2020, Amazon Web Services, Inc. or its Affiliates. Configuring
Async Invocations -
© 2020, Amazon Web Services, Inc. or its Affiliates. AWS
Lambda – Destinations for Async Invocations Amazon S3 Amazon SNS Amazon SES Amazon EventBridge Amazon CloudWatch Logs AWS Config Amazon CloudFormation AWS CodeCommit AWS Lambda Amazon SNS Amazon SQS Amazon EventBridge Lambda Function onSuccess onFailure -
© 2020, Amazon Web Services, Inc. or its Affiliates. Function
Invocations Costs Scalability New Paradigm Kinesis / DynamoDB Streams Parallelization factor (no need for fan-outs) Failure-handling ⇣ Easier to scale streaming analytics and manage errors when processing a stream -
© 2020, Amazon Web Services, Inc. or its Affiliates. Kinesis
/ DynamoDB Streams Controls -
© 2020, Amazon Web Services, Inc. or its Affiliates. Function
Invocations Latency Costs Amazon API Gateway New “HTTP APIs” ⇣ Cheaper and faster APIs Reduce application costs by up to 70% Reduce application latency by up to 50% -
© 2020, Amazon Web Services, Inc. or its Affiliates. Amazon
API Gateway – HTTP APIs Preview -
© 2020, Amazon Web Services, Inc. or its Affiliates. Function
Invocations Costs New Paradigm Application Load Balancer (ALB) Weighted Target Groups ⇣ Fine-grained deployments with ALB, too Stickiness! Create rules depending on Host, HTTP header/method, Query string, or Source IP Simpler migrations to serverless -
© 2020, Amazon Web Services, Inc. or its Affiliates. ALB
Weighted Target Groups -
© 2020, Amazon Web Services, Inc. or its Affiliates. Execution
Environment Language Support Runtimes Python 3.8 Java 11 Node.js 12 Custom Runtimes ⇣ Use your favorite programming language Easier to migrate existing apps -
© 2020, Amazon Web Services, Inc. or its Affiliates. Execution
Environment Latency Scalability VPC to VPC NAT ⇣ Integrate VPC resources in serverless apps Use new services with Lambda functions (e.g. ElastiCache) -
© 2020, Amazon Web Services, Inc. or its Affiliates. Execution
Environment Latency Costs Scalability AWS Lambda Provisioned Concurrency ⇣ No more “cold starts” Real-time apps and games Applications with a slow initialization Download config/data on /tmp -
© 2020, Amazon Web Services, Inc. or its Affiliates. AWS
Lambda – Provisioned Concurrency We do the initialization, you are responsible for the first invocation of the handler Avoid lazy initializations Integrated with Application Auto Scaling and AWS CodeDeploy -
© 2020, Amazon Web Services, Inc. or its Affiliates. Execution
Environment Costs Scalability New Paradigm AWS Step Functions Express Workflows ⇣ Build more modular apps Separate business process flow from implementation -
© 2020, Amazon Web Services, Inc. or its Affiliates. AWS
Step Functions – Express Workflows -
© 2020, Amazon Web Services, Inc. or its Affiliates. Service
Integrations Costs Scalability New Paradigm Amazon Relational Database Service (RDS) RDS Proxy ⇣ Using relational databases in serverless apps is much easier AWS Secrets Manager stores the user name and password for the database -
© 2020, Amazon Web Services, Inc. or its Affiliates. Amazon
RDS Proxy – How It Works Preview -
© 2020, Amazon Web Services, Inc. or its Affiliates. RDS
Proxy + Amazon Aurora Serverless = Sample workload using Aurora Serverless PostgreSQL -
© 2020, Amazon Web Services, Inc. or its Affiliates. Service
Integrations Costs New Paradigm Amazon EventBridge Schema Registry Rules can now be triggered by CloudWatch Alarms ⇣ Building event-driven apps with IDE integration Integrating PaaS solutions with your apps -
© 2020, Amazon Web Services, Inc. or its Affiliates. Service
Integrations Scalability New Paradigm Amazon Athena Create user defined functions (UDF) using Lambda functions Run federated queries ⇣ Using SQL for analyzing… almost anything! -
© 2020, Amazon Web Services, Inc. or its Affiliates. Amazon
Athena – Create your own data connector Preview -
© 2020, Amazon Web Services, Inc. or its Affiliates. New
Paradigm AWS Amplify Native iOS/Android Mobile Backends Amplify DataStore ⇣ Mobile backends for native apps Persistent on-device storage to write, read, and observe changes online or offline, and seamlessly sync to the cloud as well as across devices Service Integrations -
© 2020, Amazon Web Services, Inc. or its Affiliates. Latency
Scalability AWS AppSync GraphQL + Pure WebSockets ⇣ Real-time apps, universal backends, migrations Service Integrations -
© 2020, Amazon Web Services, Inc. or its Affiliates. Enhanced
Real-Time Experience on AWS AppSync -
© 2020, Amazon Web Services, Inc. or its Affiliates. Configuration
Management New Paradigm AWS AppConfig For EC2, containers, on-premises, Lambda, containers, mobile apps, IoT devices Application Environment Configuration Profile ⇣ Releasing configurations changes with fine-grained controls -
© 2020, Amazon Web Services, Inc. or its Affiliates. Configuration
Management for Lambda Functions Environment Variables Parameter Store AWS Secrets Manager AWS AppConfig In the function configuration For function-specific configurations Part of AWS Systems Manager Can be shared across multiple functions For secrets, can automate rotating secrets Integrated with the new RDS Proxy Part of AWS Systems Manager Full control during the roll out of configuration changes -
© 2020, Amazon Web Services, Inc. or its Affiliates. Observability
Costs Scalability New Paradigm Tracing – AWS X-Ray Trace Maps – for single requests Simplified identification of service disruption – in Service Maps SNS/SQS support (added in July/August) API Gateway (since 2018) ⇣ More and easier observability -
© 2020, Amazon Web Services, Inc. or its Affiliates. Observability
Costs Scalability New Paradigm Monitoring CloudWatch Embedded Metric Format Percentiles on CloudWatch metrics CloudWatch Synthetics CloudWatch ServiceLens CloudWatch Anomaly Detection (added in September) ⇣ More visibility into your application behavior -
© 2020, Amazon Web Services, Inc. or its Affiliates. Using
CloudWatch Embedded Metric Format -
© 2020, Amazon Web Services, Inc. or its Affiliates. CloudWatch
Synthetics – Monitor Application Endpoints -
© 2020, Amazon Web Services, Inc. or its Affiliates. CloudWatch
ServiceLens CloudWatch metrics and logs + AWS X-Ray traces -
© 2020, Amazon Web Services, Inc. or its Affiliates. Using
CloudWatch Anomaly Detection Alarms -
© 2020, Amazon Web Services, Inc. or its Affiliates. Editing
the Anomaly Detection Model -
© 2020, Amazon Web Services, Inc. or its Affiliates. Observability
Configuration Management Function Invocations Execution Environment Service Integrations Latency Language Support Costs Scalability New Paradigm -
© 2020, Amazon Web Services, Inc. or its Affiliates. Observability
Configuration Management Function Invocations Execution Environment Service Integrations Lots of concerns have been addressed… -
© 2020, Amazon Web Services, Inc. or its Affiliates. More
tooling available -
© 2020, Amazon Web Services, Inc. or its Affiliates. Plus:
AWS SAM Start Right 2 1 Scheduled Job Queue Processing File Processing API backend Build Source Deploy 3 -
© 2020, Amazon Web Services, Inc. or its Affiliates. Savings
plan Simplify purchasing with a flexible pricing model applying to Amazon EC2, AWS Fargate usage – Lambda coming soon Recommendations in AWS Cost Explorer Any instance family—any region AWS Fargate now and Lambda soon Flexibility Preview -
© 2020, Amazon Web Services, Inc. or its Affiliates. Roomba
Vacuum Cleaners -
© 2020, Amazon Web Services, Inc. or its Affiliates. Roomba
Vacuum Cleaners -
© 2020, Amazon Web Services, Inc. or its Affiliates. So,
what can you do with serverless, now? ✓ Web/Mobile/IoT backends ✓ Batch/streaming analytics ✓ DevOps & IT automation ✓ Voice/text chat interfaces ✓ Real-time apps, multi-player games ✓ Complex async jobs/tasks/activities ✓ Reduce costs even more ✓ Reduce complexity ✓ And much, much more! -
© 2020, Amazon Web Services, Inc. or its Affiliates. What
Can You Do with Serverless …in 2020 ? -
© 2020, Amazon Web Services, Inc. or its Affiliates. What
Are You Going to Build …in 2020 ? -
© 2020, Amazon Web Services, Inc. or its Affiliates. Thank
you! @danilop Please give me your feedback!