microservices without the servers - meetupfiles.meetup.com/1744630/seattle meetup - microservices...
TRANSCRIPT
![Page 1: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/1.jpg)
Microservices without the Servers
Vyom Nagrani Sr. Product Manager
AWS Lambda [email protected]
Ajay Nair Sr. Product Manager
AWS Lambda [email protected]
![Page 2: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/2.jpg)
• Evolution of Cloud Compute towards Serverless
• About Microservices
• What is AWS Lambda
• Microservices for data processing workloads
• Other Microservice architecture patterns
Agenda
![Page 3: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/3.jpg)
Evolution of Cloud Compute towards
Serverless
![Page 4: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/4.jpg)
Evolution of Compute – Servers
![Page 5: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/5.jpg)
Evolution of Compute – Racks
![Page 6: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/6.jpg)
Evolution of Compute – Virtualization
![Page 7: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/7.jpg)
Evolution of Compute – Colocation
![Page 8: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/8.jpg)
Evolution of Compute – Public Cloud
![Page 9: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/9.jpg)
Evolution of Compute – Containers
![Page 10: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/10.jpg)
Evolution of Compute – Serverless
![Page 11: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/11.jpg)
Evolution of Compute
No server is easier to manage than “no server”
@Werner
AWS Summit, New York, 7/9/2015
![Page 12: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/12.jpg)
What are microservices
![Page 13: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/13.jpg)
What are microservices
In short, the microservice architectural style is an approach to developing a single application as a suite of small services, each running in its own process and communicating with lightweight mechanisms, often an HTTP resource API. These services are built around business capabilities and independently deployable by fully automated deployment machinery. There is a bare minimum of centralized management of these services, which may be written in different programming languages and use different data storage technologies. -- James Lewis and Martin Fowler
http://martinfowler.com/microservices
![Page 14: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/14.jpg)
What are microservices
Microservices
Componentization via Smaller Services
Decentralized Governance
Organized around Business Capabilities
Smart endpoints and dumb pipes
Infrastructure Automation
Decentralized Data Management
![Page 15: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/15.jpg)
What are microservices
https://www.nginx.com/blog/building-microservices-using-an-api-gateway/
![Page 16: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/16.jpg)
What is AWS Lambda
![Page 17: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/17.jpg)
AWS Lambda
Serverless, event driven compute service
Lambda = microservice without servers
![Page 18: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/18.jpg)
AWS Lambda – Benefits
EVENT DRIVEN SCALE SERVERLESS SUBSECOND BILLING
![Page 19: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/19.jpg)
AWS Lambda – Capabilities
BRING YOUR OWN CODE SIMPLE RESOURCE MODEL
FLEXIBLE INVOCATION PATHS GRANULAR PERMISSIONS CONTROL
![Page 20: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/20.jpg)
AWS Lambda – How it works
MONITORING
Requests Errors
Latency Throttles
LOGGING
All metrics System/Report logs
User logs
AUTHORING
NodeJS / Java Libraries
Threads, /tmp, sockets
DEPLOYMENT
Console WYSIWYG Upload ZIP S3 bucket
![Page 21: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/21.jpg)
Microservices for data processing workloads
![Page 22: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/22.jpg)
SOURCE of data
Fleet of servers poll for changes
Listening to source Pushes to queue Pull off queue
Fleet of servers act as workers to process the data
Auto-scale worker nodes to adjust with
load
S3 objects Kinesis records
DDB Tables SNS messages
IoT Devices …
Cross AZ replication for
high availability
Load Balancer to distribute
traffic
Data processing architecture with servers
![Page 23: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/23.jpg)
SOURCE of data
Attach a Lambda function
And that’s it!
Lambda does
Listening/Polling Queuing
Autoscaling Load balancing
Data processing architecture without servers
![Page 24: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/24.jpg)
Data processing with Lambda Real-time File Processing PDF watermarking Image thumbnailing Video transcoding Document metadata Indexing Log aggregation and filtering RSS feed processing
Database
Streams
Blob
Blob
Database
Streams
Data loading/DB triggers Data validation Threshold alerting Dynamic backups Analytics ETL
Realtime Stream processing Client activity tracking Metrics generation Data cleansing Log filtering Indexing and searching Log routing IoT backends
![Page 25: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/25.jpg)
Real time file processing demo
![Page 26: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/26.jpg)
Other Microservice patterns with Lambda
Blob Database Other APIs
API Backends CRUD backends Data validation Trigger workflows lookups (e.g. whatsMyIP)
IoT Backends Device logic Data synching Alexa Skills
API Backends CRUD backends Data validation Trigger workflows lookups (e.g. whatsMyIP)
Blob
Database
Streams
SNS
CloudFormation
Simple Workflow
Pub-sub handlers CloudWatch alarms (SNS) Event bridges Smart notifications
AWS Service extensions Simple Workflow CloudFormation
![Page 27: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/27.jpg)
CRUD Backend demo
![Page 28: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/28.jpg)
What’s next for you?
1. Go to the AWS console to create and test your first Lambda function. The first 1M requests each month are on us!
2. Enjoy your serverless, event driven microservice 3. Create new ways to process data, build backends and
manage service workers
![Page 29: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/29.jpg)
THANK YOU
Q&A
Visit http://aws.amazon.com/lambda, the AWS Compute blog, and the Lambda forum to learn more and get started using Lambda.
![Page 30: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/30.jpg)
Case study: VidRoll
![Page 31: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/31.jpg)
The Challenge • EC2 used for (a) powering the business
logic (b) dynamic configuration needed to bid on video ads in real time across multiple exchanges (c) real-time transcoding of video ads and running MySQL databases
• Difficulty in managing a cluster of EC2 (provision, manage, and scale the EC2 instances)
• Overhead of operations elements – instance type selection, scaling, deployment logic, and software configurations
• In order to scale the business quickly, developers needed to focus on specialized tasks and not worry about IT infrastructure.
The Benefits • Developers eliminate the need to
understand or worry about infrastructure
• Code does not need to be rewritten later as the system changes (productivity gains)
• What VidRoll can now do with 2-3 engineers would usually take 8-10 engineers because code reusability becomes a growing performance advantage.
• VidRoll has grown revenue by 10x without hiring additional technical resources to manage volume, passing the cost savings to customers.
The Solution
VidRoll case study
![Page 32: Microservices without the Servers - Meetupfiles.meetup.com/1744630/Seattle Meetup - Microservices without th… · Microservices without the Servers Vyom Nagrani Sr. Product Manager](https://reader030.vdocuments.mx/reader030/viewer/2022040214/5ec460aa11d3e40cc173fc1a/html5/thumbnails/32.jpg)
VidRoll case study