Download presentation
Presentation is loading. Please wait.
Published byJoshua Jesse Roberts Modified over 6 years ago
1
“No Server is easier to manage than no server”
Karthi Thyagarajan AWS Solutions Architect
2
Overview: Why Serverless?
3
Challenges of server-based designs:
Why Serverless? Challenges of server-based designs: Operational overhead Create and Manage VMs or EC2 Instances Patching Operating Systems, Web Servers, App Servers Chunkier units of scale – at the VM level Friction when implementing microservices The first two points are pretty straightforward. Regarding the point about microservices – designers have to leverage containerization technologies like Docker when working in the server-based world.
4
Why Serverless? (cont’d)
Benefits of Serverless designs: Low operational overhead No OS patching or managing VMs or EC2 instances More granular units of scale Simpler to implement microservices Lower cost Mention - Could be cheaper because of lower operational overhead
5
Spectrum of AWS Offerings
“On EC2” Managed Serverless AWS Lambda Amazon Kinesis Amazon EMR Amazon Elasticsearch Service Amazon EC2 Amazon ElastiCache Amazon RDS Amazon Redshift Amazon S3 Amazon DynamoDB Mention - Could be cheaper because of lower operational overhead Microsoft SQL Server Amazon API Gateway Amazon SQS AWS IoT
6
Serverless Patterns 3 Tier Web Application Stream Processing
Operations Automation Dynamic Data Triggers
7
Pattern 1: 3 Tier Web Application
8
Web Application: Characteristics
Typically 3-tiered: Presentation tier Application tier Data tier Presentation and application tier are typically stateless Data tier is some sort of structured store: relational or NoSQL
9
3 Tier Web Architecture with Servers
10
Serverless 3 Tier Web Architecture
Data tier App tier Presentation tier Amazon S3 Amazon DynamoDB AWS Lambda Amazon API Gateway + Monitoring is closer to your business needs. Budgets and cost profile for the services. Only pay while it is running. What you pay is close to how you make money. Amazon CloudFront
11
Demo http://bit.ly/1VD8xYa Pattern1 Web Demo:
Start with middle tier API GW. Show the Message Resource, not the Talkers resource (which is blank for now). Show the Lambda function by clicking on the integration point in API GW. Show DDB table. Web page – single page app, show S3, and public permissions. Mention AngularJS.
12
Applicability SquirrelBin Augmenting an existing application
A Serverless Microservice Using AWS Lambda Augmenting an existing application For instance, add product search capability to an existing application Mobile application built on AWS to complement traditional 3-tier web app
13
Pattern 2: Stream Processing & Analytics
14
Stream Processing: Characteristics
High ingest rate Near real-time processing (low latency from ingest to process) Spiky traffic (lots of devices with intermittent network connections) Message durability Message ordering
15
Stream Processing Architecture with Servers
Load balancer to distribute traffic Cross-AZ replication for high availability Auto-scale worker nodes to adjust with load SOURCE of data Listening to source Pushes to queue Pull off queue Fleet of servers poll for changes Fleet of servers act as workers to process the data S3 objects Amazon Kinesis records DynamoDB tables SNS messages IoT devices … Application code
16
Server-less Stream Processing: Sensor Data Aggregation
Lots sensors sending frequent measurements Calculate aggregate stats over a time-window (3s) in near real-time
17
Sensor Data Aggregation: Data Flow
Amazon S3: Visualization Web App Amazon DynamoDB: Aggregates Table Amazon Kinesis: Stream AWS Lambda: Stream Processor Sensors
18
Processing a Kinesis stream with Lambda
19
Demo
20
Applicability Web Events Log processing Clickstream analytics
Analyze a Time Series in Real Time with AWS Lambda, Amazon Kinesis and Amazon DynamoDB Streams Log processing Real time processing of Log Data with Subscriptions (CloudWatch Logs to Lambda) Clickstream analytics Transaction processing
21
Customers running real-time data stream processing on Kinesis+Lambda
“I want to apply custom logic to process data being uploaded through my Kinesis stream”. Client activity tracking Metrics generation Data cleansing Log filtering Indexing and searching Log routing Live alarms and notifications AWS Lambda Aggregate statistics Real-time analytics Kinesis Stream verify data formats, audit out-of-range values, filter and copy data to other tables
22
Indexing DynamoDB using Elastic Search and Lambda
23
Pattern 3: Operations Automation
24
Operations Automation: Characteristics
Respond to alarms or events Periodic jobs Auditing and Notification Extend AWS functionality …All while being Highly Available and Scalable
25
Dynamic DNS using Route53 using CloudWatch Events and Lambda
Amazon EC2 Instance State Changes Amazon CloudWatch Events: Rule Triggered AWS Lambda: Update R53 Amazon Route53: Private Hosted Zone CNAME = ‘xyz.example.com’ xyz.example.com A From: Amazon DynamoDB: EC2 Instance Properties
26
Demo
27
Applicability Scheduled Jobs Auditing and Notification
Scheduling EBS Snapshots (Part 1) Scheduling EBS Snapshots (Part 2) – Delete old snapshots Scheduling SSH Jobs using Lambda Auditing and Notification AWS Config Rules (AWS Managed) and Rule Repository Sample Rule “Ensure IAM User has MFA Enabled” Sample Rule “Ensure all EC2 Instances are of a Given Type”
28
Applicability Respond to Alarms and Events
Building a Dynamic DNS for Route 53 using CloudWatch Events and Lambda Scaling Amazon ECS Services Automatically Using Amazon CloudWatch and AWS Lambda Auto Scaling Group lifecycle hooks Using AWS Lambda with Auto Scaling Lifecycle Hooks (attach a second ENI to every server in an ASG) Extending CloudFormation using Custom Resources Look up AMI IDs: Refer to resources in another stack:
29
Pattern 4: Dynamic Data Triggers
30
Characteristics Perform actions upon data ingestion Highly available
Scalable Event driven, avoid polling
31
Image Thumbnail Creation
33
Demo
34
Applicability Image / Video transcoding Indexing S3
Tutorial: Using AWS Lambda with S3 Indexing S3 Building and Maintaining an Amazon S3 Metadata Index without Servers Automated log analysis AWS Service Logs: Access Logs from S3, ELB, CloudFront Access Logs, CloudTrail How to Configure Rate-Based Blacklisting with AWS WAF and AWS Lambda How to Use AWS WAF to Block IP Addresses That Generate Bad Requests Billing analysis Process AWS Detailed Billing Reports
35
Indexing S3 Objects in DynamoDB
From:
36
Indexing tables or notifications
Customers running dynamic data ingestion and processing using S3+Lambda “I want to apply custom logic to process content being uploaded to my data store”. Watermarking / thumbnailing Transcoding Indexing and deduplication Aggregation and filtering Pre processing Content validation Processed files verify data formats, audit out-of-range values, filter and copy data to other tables Amazon S3 Bucket Events AWS Lambda Indexing tables or notifications
37
Further Reading JAWS / Serverless at http://www.serverless.com/
Getting Started with JAWS on Amazon Web Services AWS Serverless Multi-Tier Architectures Microservices without the Servers The Serverless Start-up
38
Further Watching AWS re:Invent 2015 | (ARC308) The Serverless Company Using AWS Lambda AWS re:Invent 2015 | (CMP301) AWS Lambda and the Serverless Cloud AWS re:Invent 2015 | (MBL302) Building Scalable, Serverless Mobile and IoT Back Ends AWS re:Invent 2015 | (GAM401) Build a Serverless Mobile Game with Amazon Cognito, Lambda & DynamoDB AWS re:Invent 2015 | (CMP407) Lambda as Cron: Scheduling Invocations in AWS Lambda AWS re:Invent 2014 | Netflix Gains New Efficiencies using AWS Lambda AWS re:Invent 2015 | (DEV203) Amazon API Gateway & AWS Lambda to Build Secure and Scalable APIs AWS re:Invent 2015 | (CMP403) AWS Lambda: Simplifying Big Data Workloads AWS re:Invent 2015 | (DVO209) JAWS: The Monstrously Scalable Serverless Framework
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.