SlideShare ist ein Scribd-Unternehmen logo
1 von 50
Welcome to the
Manchester Community College, Manchester NH
November 2, 2019
@bsubra
SERVERLESS
COMPUTING
APIS, SERVERLESS FUNCTIONS, MICROSERVICES - HOW TO GET YOUR PRODUCT QUICKLY
TO MARKET?
A BIG thank you to our 2019 Sponsors!
Venue Sponsor
Platinum Sponsor (Lunch & Refreshments)
Diamond Sponsor (Lunch & iPad Raffle)
Gold Sponsor (Speaker Appreciation)
Silver Sponsor (Attendee Appreciation)
Another BIG thank you to our in-kind sponsors!
Raffle: Licenses
Raffle: Meadow / Hack Kit Pro
Chocolates
Speaker / Schedule Management
Raffle: Weekday Lift Tickets
Raffle: Licenses
@bsubra
@bsubra
@bsubra
AGENDA
• Why?
• What?
• How? - Demos
• Architectures
• EDA, Patterns, Best Practices
• Advantages
• Disadvantages
• Next Steps
@bsubra
STORY OF A CENSUS
@bsubra
WHY?
@bsubra
WHY?
• Smallest Unit of Compute – Pure Code
• Super, Hyper-Scalable
• Rapid Iteration, CI, CD, Quickest Delivery
• Extreme multi-tenancy
• Very Polyglot friendly (Java, JS, C#, Python,
Powershell, F#, Typescript, PHP, Go and so on)
• Easier to Collaborate – Microservices, APIs
• Deploy Independently – Go live to production
in seconds
@bsubra
WHY? – FUTURE OF TECH INDUSTRY
@bsubra
SERVERLESS <> CLOUD
@bsubra
MANDATORY VIEWING
Source: IDC: Generating Value Through IT Agility & Business Scalability with Serverless
Platform
@bsubra
@bsubra
@bsubra
WHAT?
@bsubra
WHAT?
• Abstraction of backend infrastructure
Completely
• Execution environment for single purpose
functions
• Hosted in public cloud or on-premise
• Serverless functions have a runtime in a
stateless container
• Node.JS, JavaScript, C#, Python, Java
• Event-driven Startup Triggers / Instant Scale-
out or Scale-in
• Micro-billing instead of per-hour / per-month
billing
@bsubra
AWS APPS - COMPARISON
@bsubra
GCP: WHICH
SERVERLESS
COMPUTE
PLATFORM IS
RIGHT FOR
YOU?
@bsubra
DEMOS
@bsubra
MICROSERVICES ARCHITECTURE
• Services can communicate via
• through synchronous API requests (for example API
Gateway)
• through asynchronous messaging between services (for
example SQS and SNS)
• through a state machine orchestrator
• State: Backend-as-a-Service (Baas): infrastructure
components managed by a Cloud Provider
• Google Cloud Firestore
• Azure Storage / AWS S3 / Google Cloud Storage
• CosmosDB / DynamoDB
• Azure Kubernetes Service (AKS)
• Google BigQuery
@bsubra
SERVERLESS ARCHITECTURE
@bsubra
EVENT DRIVEN ARCHITECTURE (EDA)
• Design Pattern around the Production
and Reaction to Events
• Serverless Functions are triggered by
Events
• Examples of Events
• A File uploaded to an S3 bucket
• Inserts on a DynamoDB Table
• A Message published to an SNS topic –
PubSub
• A CloudWatch Alert
• A message is available to read from a
Kinesis stream
@bsubra
ADVANTAGES
• Asynchronous, Concurrent
• Infrequent or has Sporadic Demand
• Stateless, Ephemeral
• Highly Dynamic in terms of Changing Business
Requirements
@bsubra
EXAMPLES OF SERVERLESS USE CASES
• Multimedia processing
• Database changes or Change Data Capture
• IoT sensor input messages
• Stream processing at scale
• Chat bots
• Batch jobs scheduled tasks
• HTTP REST APIs and web apps
• Mobile back ends
• Business logic
• Continuous integration pipeline
Source: CNCF Serverless Whitepaper
v1.0
@bsubra
TIPS AND TRICKS
• Limit your Function Size (JVM Startup time especially)
• Remember Execution is Async
• Do not assume function container reuse but take advantage of it
• Audit dependencies to keep bundle sizes small.
• CloudWatch's default log retention period is forever.
• Structure your logs to ease alert creation and debugging
• Understand AWS account limits
• Think twice before dynamically provisioning AWS resources.
• Price - Is Serverless really as cheap as everyone claims? (dev.to) Unless you are
operating at massive scale, serverless is not just cheap, it's a steal.
@bsubra
BEST PRACTICES
• Scrutinize and research before attaching new input/event sources
• Keep the functions’ permissions least privileged and maintain a least privileged build system
• Amount of code that can access sensitive data be reduced, exceptions are handled and input is
validated
• Avoid embedding secrets and access keys in code
• Do not store access keys or credentials in source code repositories
• Throttle and define quotas on the amount of requests that go through
• Keep data encrypted that is stored at rest
• Scrutinize and keep tab on third party API services for vulnerabilities
• Scan third party libraries for potential vulnerabilities and try to keep them up-to-date
• Carefully examine granting permissions that allow creation, modification or removal of the resources
@bsubra
@bsubra
SERVERLESS FAILURE STORIES
• Serverless out of control
• Mo’ developers, mo’ problems: How serverless has trouble with teams
• Beware “RunOnStartup” in Azure Functions – a serverless horror story
• Serverless: A lesson learned. The hard way.
• Serverless: 15% slower and 8x more expensive
@bsubra
DYNAMODB - BEST PRACTICES
• Where it could be Used?
• Wherever we see relationships…
• Document management
• Process control
• Social network
• Data trees
• IT monitoring
• Takeaways
• NoSQL does not mean non-relational
• The ERD still matters
• RDBMS is not deprecated by NoSQL
• Use NoSQL for OLTP or DSS at Scale.
• Use RDBMS for OLAP or OLTP when Scale is not important.
@bsubra
DYNAMODB ANTI-PATTERNS
• Prewritten application tied to a traditional relational database – If you are attempting to port an
existing application to the AWS cloud and need to continue using a relational database, you may elect
to use either Amazon RDS (Amazon Aurora, MySQL, PostgreSQL, Oracle, or SQL Server), or one of the
many pre-configured Amazon EC2 database AMIs. You can also install your choice of database
software on an EC2 instance that you manage.
• Joins or complex transactions – While many solutions are able to leverage DynamoDB to support
their users, it’s possible that your application may require joins, complex transactions, and other
relational infrastructure provided by traditional database platforms. If this is the case, you may want to
explore Amazon Redshift, Amazon RDS, or Amazon EC2 with a self-managed database.
• Binary large objects (BLOB) data – If you plan on storing large (greater than 400 KB) BLOB data,
such as digital video, images, or music, you’ll want to consider Amazon S3. However, DynamoDB still
has a role to play in this scenario, for keeping track of metadata (e.g., item name, size, date created,
owner, location, etc.) about your binary objects.
• Large data with low I/O rate –DynamoDB uses SSD drives and is optimized for workloads with a
high I/O rate per GB stored. If you plan to store very large amounts of data that are infrequently
accessed, other storage options may be a better choice, such as Amazon S3.
@bsubra
LAMBDA - BEST PRACTICES
• Minimize package size to necessities
• Separate the Lambda handler from core logic
• Read only what you need
• Properly Indexed Databases
• Query Filters in Aurora
• Use S3 Select
• Dynamic Logic via Configuration
• Per Function - Use Environment Variables to modify operational behavior
• Cross Function – Amazon Parameter Store / Secrets Manager
• Self-contain dependencies in your function package
• Leverage “Max Memory Used” to right-size your functions
• Use Functions to TRANSORM (not for TRANSPORT)
• Delete large unused functions (used to be 75GB limit)
@bsubra
LAMBDA – ANTI-PATTERNS
• Long-running applications – Each Lambda function must complete within 300
seconds. For long-running applications that may require jobs to run longer than five
minutes, Amazon EC2 is recommended or you create a chain of Lambda functions
where function 1 calls function 2, which calls function 3, and so on until the process is
completed.
• Dynamic websites – While it is possible to run a static website with Lambda, running
a highly dynamic and large volume website can be performance prohibitive. Using
Amazon EC2 and Amazon CloudFront would be a recommended use case.
• Stateful applications –Lambda code must be written in a “stateless” style; that is, it
should assume there is no affinity to the underlying compute infrastructure. Local file
system access, child processes, and similar artifacts may not extend beyond the
lifetime of the request, and any persistent state should be stored in Amazon S3,
DynamoDB, or another Internet-available storage service.
@bsubra
SERVERLESS
WEB APP
ON AZURE
@bsubra
@bsubra
SERVERLESS
APP WITH
AWS AMPLIFY
@bsubra
HOW AWS BUILT A PRODUCTION SERVICE USING SERVERLESS TECHNOLOGIES
@bsubra
AWS SERVERLESS DATA LAKE
@bsubra
GOOGLE GCP
@bsubra
HOW MATURE ARE YOU? -
AUTOMATION
@bsubra
Features AWS Lambda Azure Functions Google Cloud Functions
Language
Support Node.js, Java, C#, Python Node.js, C#, F#, Python, PHP Node.js
Security
AWS IAM, VPC
OAuth providers such as Azure Active Directory, Facebook, Google,
Twitter, and Microsoft Account Cloud IAM
Monitoring Cloudwatch Application Insights Stackdriver Monitoring
Logging Cloudwatch Application Insights Analytics Stackdriver Logging
Auditing CloudTrail Azure Audit Logs Cloud Audit Logging
Alerts Cloudwatch Alarms Application Insights, Log Analytics, and Azure Monitor Stackdriver Monitoring
Tooling
Support CodePipeline, Code Build Azure Portal, Azure Powershell, Azure CLI, Azure SDK gcloud CLI for functions
Debugging
Support AWS X-Ray
Azure CLI - local debugging,
Azure App Service - remote debugging Stackdriver Debugger
Pricing
it depends
Execution Time: $0.000016/GBs, 400,000 GBs/month are free
Total Executions: $0.20/million executions, with 1 million
executions/month free
Invocations: $0.40/million invocations with 2 million invocations free
Compute Time: $0.0000025/GBsec with 400,00 GB-sec/month free &
$0.0000100/GHzsec with 200,000 GHz-sec/month free
Limits
Memory allocation range: Min. 128 MB / Max. 1536 MB (with 64 MB
increments)
Ephemeral disk capacity ("/tmp" space): 512 MB
Number of file descriptors: 1,024
Number of processes and threads (combined total): 1,024
Maximum execution duration per request: 300 seconds
Invoke request body payload size (RequestResponse): 6 MB
Invoke request body payload size (Event): 128 K
Invoke response body payload size (RequestResponse): 6 MB
Allow only 10 concurrent executions per function
No limitations on max. execution time limit
Resource, Time and Rate Limits are defined under Google Cloud Functions
Quota limits
@bsubra
DISADVANTAGES
• Portability
• Automation / DevOps
• Cross-Cloud Communication
• The Cold Start Problem
• Applications that haven't been used recently
take longer to startup and to handle the first
request.
• Because serverless happens on use, there
aren’t dedicated instances ready to handle
requests
• Solution: Run a function in a dedicated
container/VM, not serverless
@bsubra
DASHBOARD SHOWS LINK BETWEEN PERFORMANCE & COSTS
@bsubra
SECURITY: SHARED RESPONSIBILITY MODEL
@bsubra
SECURITY RISKS
1. Function Event-Data Injection
2. Broken Authentication
3. Insecure Serverless Deployment Configuration
4. Overprivileged Function Permissions and Roles
5. Inadequate Function Monitoring and Logging
6. Insecure Third-Party Dependencies
7. Insecure Application Secrets Storage
8. Denial-of-Service and Financial Resource Exhaustion
9. Serverless Business Logic Manipulation
10. Improper Exception Handling and Verbose Error Messages
11. Legacy/Unused Functions & Cloud Resources
12. Cross-Execution Data Persistency
Source: CSA - The 12 Most Critical Risks for Serverless Applications
2019
@bsubra
SERVERLESS WEB APP SECURITY
@bsubra
CONSIDERATIONS FOR THE ENTERPRISE
• Cloud Silos
• Enterprise Eventing
• Serverless skills gap
• Monitoring vs. Observability
• Stateful vs. Stateless
• Forecasting costs
• Where serverless falls short
Source: The New Stack Serverless Survey 2018
Q: What are the top three areas in which serverless falls short of expectations?
@bsubra
WORKS CITED
• Serverless Architectures - Martin Fowler
• Serverless on Google Cloud Platform: an
Introduction with Serverless Store Demo
• Introduction to Serverless: RISE Conference 2018 -
Hong Kong Developer Workshop: Introduction to
Serverless - Shaun Ray
• Serverless is a Doctrine, not a Technology - Paul
Johnston – Medium
• The Serverless Sea Change
• How AWS built a production service using
serverless technologies | AWS Open Source Blog
• Serverless Architectural Patterns and Best Practices
| AWS Architecture Blog
• Contemporary Views on Serverless and
Implications - Subbu’s Blog
@bsubra
@bsubra
SERVERLESS ON GOOGLE CLOUD PLATFORM
• App Engine | Google Cloud
• 1. Auth, Storage, Event Streaming, and Third-Party APIs (Firebase Authentication,
Cloud Storage, Cloud Firestore, Cloud Pub/Sub and Third-Party APIs)
• 11. Machine Learning, AI, Data Analytics, and Data Visualization (Cloud Vision API,
Cloud AutoML, DialogFlow +Google Assistant integration, BigQuery and Data Studio)
• 111. Serverless Computing, Management Tools, and Cron Jobs (App Engine, Cloud
Functions, Cloud Scheduler, Stackdriver Logging, Stackdriver Monitoring, and
Stackdriver Tracing)
• 1111. Hacking Google Cloud Run
@bsubra
CALL TO ACTION
1. Write an AWS Lambda from Template
• How do I get started with creating serverless applications?
2. Make your monolithic app use Step Functions
3. Try how Azure Kubernetes Service (AKS) can deploy your legacy apps
4. Make your next project be event driven with Azure Event Grid, or GCP Cloud Pub/Sub
• Building a Reliable Serverless Application in a Weekend
5. Become familiar with application observability with comprehensive logging, metrics, and
tracing
6. Follow folks pushing Serverless in twitter
7. Read a book
• Serverless apps: Architecture, patterns, and Azure implementation | Microsoft Docs
8. Watch Videos like
• AWS re:Invent: Accelerate Innovation & Maximize Business Value w/ Serverless Apps (SRV212-R1)
• Keynote: Serverless, Not So FaaS - Kelsey Hightower, Kubernetes Community Member, Google
Thank you

Weitere ähnliche Inhalte

Was ist angesagt?

Getting to 1.5M Ads/sec: How DataXu manages Big Data
Getting to 1.5M Ads/sec: How DataXu manages Big DataGetting to 1.5M Ads/sec: How DataXu manages Big Data
Getting to 1.5M Ads/sec: How DataXu manages Big Data
Qubole
 
Scalable Web Architectures: Common Patterns and Approaches
Scalable Web Architectures: Common Patterns and ApproachesScalable Web Architectures: Common Patterns and Approaches
Scalable Web Architectures: Common Patterns and Approaches
adunne
 

Was ist angesagt? (19)

MongoDB and AWS: Integrations
MongoDB and AWS: IntegrationsMongoDB and AWS: Integrations
MongoDB and AWS: Integrations
 
Getting to 1.5M Ads/sec: How DataXu manages Big Data
Getting to 1.5M Ads/sec: How DataXu manages Big DataGetting to 1.5M Ads/sec: How DataXu manages Big Data
Getting to 1.5M Ads/sec: How DataXu manages Big Data
 
(BDT322) How Redfin & Twitter Leverage Amazon S3 For Big Data
(BDT322) How Redfin & Twitter Leverage Amazon S3 For Big Data(BDT322) How Redfin & Twitter Leverage Amazon S3 For Big Data
(BDT322) How Redfin & Twitter Leverage Amazon S3 For Big Data
 
What's New with Amazon DynamoDB - AWS Online Tech Talks
What's New with Amazon DynamoDB - AWS Online Tech TalksWhat's New with Amazon DynamoDB - AWS Online Tech Talks
What's New with Amazon DynamoDB - AWS Online Tech Talks
 
Day 2 - Amazon RDS - Letting AWS run your Low Admin, High Performance Database
Day 2 - Amazon RDS - Letting AWS run your Low Admin, High Performance DatabaseDay 2 - Amazon RDS - Letting AWS run your Low Admin, High Performance Database
Day 2 - Amazon RDS - Letting AWS run your Low Admin, High Performance Database
 
Compare DynamoDB vs. MongoDB
Compare DynamoDB vs. MongoDBCompare DynamoDB vs. MongoDB
Compare DynamoDB vs. MongoDB
 
DynamodbDB Deep Dive
DynamodbDB Deep DiveDynamodbDB Deep Dive
DynamodbDB Deep Dive
 
DataTalks.Club - Building Scalable End-to-End Deep Learning Pipelines in the ...
DataTalks.Club - Building Scalable End-to-End Deep Learning Pipelines in the ...DataTalks.Club - Building Scalable End-to-End Deep Learning Pipelines in the ...
DataTalks.Club - Building Scalable End-to-End Deep Learning Pipelines in the ...
 
Database Migration – Simple, Cross-Engine and Cross-Platform Migration
Database Migration – Simple, Cross-Engine and Cross-Platform MigrationDatabase Migration – Simple, Cross-Engine and Cross-Platform Migration
Database Migration – Simple, Cross-Engine and Cross-Platform Migration
 
Scaing databases on the cloud
Scaing databases on the cloudScaing databases on the cloud
Scaing databases on the cloud
 
Cassandra Day SV 2014: Spark, Shark, and Apache Cassandra
Cassandra Day SV 2014: Spark, Shark, and Apache CassandraCassandra Day SV 2014: Spark, Shark, and Apache Cassandra
Cassandra Day SV 2014: Spark, Shark, and Apache Cassandra
 
Scalable Stream Processing with Apache Samza
Scalable Stream Processing with Apache SamzaScalable Stream Processing with Apache Samza
Scalable Stream Processing with Apache Samza
 
Architecting applications in the AWS cloud
Architecting applications in the AWS cloudArchitecting applications in the AWS cloud
Architecting applications in the AWS cloud
 
(BDT404) Large-Scale ETL Data Flows w/AWS Data Pipeline & Dataduct
(BDT404) Large-Scale ETL Data Flows w/AWS Data Pipeline & Dataduct(BDT404) Large-Scale ETL Data Flows w/AWS Data Pipeline & Dataduct
(BDT404) Large-Scale ETL Data Flows w/AWS Data Pipeline & Dataduct
 
(GAM301) Real-Time Game Analytics with Amazon Kinesis, Amazon Redshift, and A...
(GAM301) Real-Time Game Analytics with Amazon Kinesis, Amazon Redshift, and A...(GAM301) Real-Time Game Analytics with Amazon Kinesis, Amazon Redshift, and A...
(GAM301) Real-Time Game Analytics with Amazon Kinesis, Amazon Redshift, and A...
 
Introduction to Database Services
Introduction to Database ServicesIntroduction to Database Services
Introduction to Database Services
 
Real-Time Event Processing
Real-Time Event ProcessingReal-Time Event Processing
Real-Time Event Processing
 
Scalable Web Architectures: Common Patterns and Approaches
Scalable Web Architectures: Common Patterns and ApproachesScalable Web Architectures: Common Patterns and Approaches
Scalable Web Architectures: Common Patterns and Approaches
 
Running MongoDB on AWS
Running MongoDB on AWSRunning MongoDB on AWS
Running MongoDB on AWS
 

Ähnlich wie Serverless architectures: APIs, Serverless Functions, Microservices - How to get your product quickly to market?

Ähnlich wie Serverless architectures: APIs, Serverless Functions, Microservices - How to get your product quickly to market? (20)

Create cloud service on AWS
Create cloud service on AWSCreate cloud service on AWS
Create cloud service on AWS
 
Amazon Aurora New Features - September 2016 Webinar Series
Amazon Aurora New Features - September 2016 Webinar SeriesAmazon Aurora New Features - September 2016 Webinar Series
Amazon Aurora New Features - September 2016 Webinar Series
 
AWS Webcast - Managing Big Data in the AWS Cloud_20140924
AWS Webcast - Managing Big Data in the AWS Cloud_20140924AWS Webcast - Managing Big Data in the AWS Cloud_20140924
AWS Webcast - Managing Big Data in the AWS Cloud_20140924
 
Database and Analytics on the AWS Cloud
Database and Analytics on the AWS CloudDatabase and Analytics on the AWS Cloud
Database and Analytics on the AWS Cloud
 
JustGiving | Serverless Data Pipelines, API, Messaging and Stream Processing
JustGiving | Serverless Data Pipelines, API, Messaging and Stream ProcessingJustGiving | Serverless Data Pipelines, API, Messaging and Stream Processing
JustGiving | Serverless Data Pipelines, API, Messaging and Stream Processing
 
Data warehousing in the era of Big Data: Deep Dive into Amazon Redshift
Data warehousing in the era of Big Data: Deep Dive into Amazon RedshiftData warehousing in the era of Big Data: Deep Dive into Amazon Redshift
Data warehousing in the era of Big Data: Deep Dive into Amazon Redshift
 
AWS Canberra WWPS Summit 2013 - AWS for Web Applications
AWS Canberra WWPS Summit 2013 - AWS for Web ApplicationsAWS Canberra WWPS Summit 2013 - AWS for Web Applications
AWS Canberra WWPS Summit 2013 - AWS for Web Applications
 
Serverless Architecture Patterns
Serverless Architecture PatternsServerless Architecture Patterns
Serverless Architecture Patterns
 
Serverless design considerations for Cloud Native workloads
Serverless design considerations for Cloud Native workloadsServerless design considerations for Cloud Native workloads
Serverless design considerations for Cloud Native workloads
 
AWS Summit Auckland - Building a Server-less Data Lake on AWS
AWS Summit Auckland - Building a Server-less Data Lake on AWSAWS Summit Auckland - Building a Server-less Data Lake on AWS
AWS Summit Auckland - Building a Server-less Data Lake on AWS
 
Scaling on AWS for the First 10 Million Users at Websummit Dublin
Scaling on AWS for the First 10 Million Users at Websummit DublinScaling on AWS for the First 10 Million Users at Websummit Dublin
Scaling on AWS for the First 10 Million Users at Websummit Dublin
 
Scaling on AWS for the First 10 Million Users at Websummit Dublin
Scaling on AWS for the First 10 Million Users at Websummit DublinScaling on AWS for the First 10 Million Users at Websummit Dublin
Scaling on AWS for the First 10 Million Users at Websummit Dublin
 
Amazon Aurora
Amazon AuroraAmazon Aurora
Amazon Aurora
 
PASS_Summit_2019_Azure_Storage_Options_for_Analytics
PASS_Summit_2019_Azure_Storage_Options_for_AnalyticsPASS_Summit_2019_Azure_Storage_Options_for_Analytics
PASS_Summit_2019_Azure_Storage_Options_for_Analytics
 
Scaling on AWS for the First 10 Million Users
Scaling on AWS for the First 10 Million UsersScaling on AWS for the First 10 Million Users
Scaling on AWS for the First 10 Million Users
 
Serverless Architecture Patterns
Serverless Architecture PatternsServerless Architecture Patterns
Serverless Architecture Patterns
 
serverless_architecture_patterns_london_loft.pdf
serverless_architecture_patterns_london_loft.pdfserverless_architecture_patterns_london_loft.pdf
serverless_architecture_patterns_london_loft.pdf
 
AWS re:Invent 2016: Amazon Aurora Best Practices: Getting the Best Out of You...
AWS re:Invent 2016: Amazon Aurora Best Practices: Getting the Best Out of You...AWS re:Invent 2016: Amazon Aurora Best Practices: Getting the Best Out of You...
AWS re:Invent 2016: Amazon Aurora Best Practices: Getting the Best Out of You...
 
ENT309 Scaling Up to Your First 10 Million Users
ENT309 Scaling Up to Your First 10 Million UsersENT309 Scaling Up to Your First 10 Million Users
ENT309 Scaling Up to Your First 10 Million Users
 
ENT309 scaling up to your first 10 million users
ENT309 scaling up to your first 10 million usersENT309 scaling up to your first 10 million users
ENT309 scaling up to your first 10 million users
 

Mehr von Bala Subra

Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...
Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...
Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...
Bala Subra
 
Demystifying Windows Communication Foundation
Demystifying Windows Communication FoundationDemystifying Windows Communication Foundation
Demystifying Windows Communication Foundation
Bala Subra
 

Mehr von Bala Subra (20)

Windows Azure Sdk
Windows Azure SdkWindows Azure Sdk
Windows Azure Sdk
 
Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...
Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...
Mobile Development Architecture Ppt with Slides, Book Notes on using Web Silv...
 
Dean Keynote Ladis2009
Dean Keynote Ladis2009Dean Keynote Ladis2009
Dean Keynote Ladis2009
 
.NET Debugging Tips and Techniques
.NET Debugging Tips and Techniques.NET Debugging Tips and Techniques
.NET Debugging Tips and Techniques
 
Scalable Resilient Web Services In .Net
Scalable Resilient Web Services In .NetScalable Resilient Web Services In .Net
Scalable Resilient Web Services In .Net
 
Driver Debugging Basics
Driver Debugging BasicsDriver Debugging Basics
Driver Debugging Basics
 
What is new in WCF 4.0?
What is new in WCF 4.0?What is new in WCF 4.0?
What is new in WCF 4.0?
 
Advanced Windows Debugging
Advanced Windows DebuggingAdvanced Windows Debugging
Advanced Windows Debugging
 
System Center: Virtual Machine Manager 2008 Version 2.0
System Center: Virtual Machine Manager 2008 Version 2.0System Center: Virtual Machine Manager 2008 Version 2.0
System Center: Virtual Machine Manager 2008 Version 2.0
 
Parallel Computing For Managed Developers
Parallel Computing For Managed DevelopersParallel Computing For Managed Developers
Parallel Computing For Managed Developers
 
IT Management Firestarter
IT Management FirestarterIT Management Firestarter
IT Management Firestarter
 
Demystifying Windows Communication Foundation
Demystifying Windows Communication FoundationDemystifying Windows Communication Foundation
Demystifying Windows Communication Foundation
 
Basics &amp; Intro to SQL Server Reporting Services: Sql Server Ssrs 2008 R2
Basics &amp; Intro to SQL Server Reporting Services: Sql Server Ssrs 2008 R2Basics &amp; Intro to SQL Server Reporting Services: Sql Server Ssrs 2008 R2
Basics &amp; Intro to SQL Server Reporting Services: Sql Server Ssrs 2008 R2
 
Denny Lee\'s Data Camp v1.0 talk on SSRS Best Practices for IT
Denny Lee\'s Data Camp v1.0 talk on SSRS Best Practices for ITDenny Lee\'s Data Camp v1.0 talk on SSRS Best Practices for IT
Denny Lee\'s Data Camp v1.0 talk on SSRS Best Practices for IT
 
BizTalk 2010 with Appfabric Hosting in the Cloud: WCF Services vs BT2010
BizTalk 2010 with Appfabric Hosting in the Cloud: WCF Services vs BT2010BizTalk 2010 with Appfabric Hosting in the Cloud: WCF Services vs BT2010
BizTalk 2010 with Appfabric Hosting in the Cloud: WCF Services vs BT2010
 
Biz talk BI
Biz talk BIBiz talk BI
Biz talk BI
 
How to ace your .NET technical interview :: .Net Technical Check Tuneup
How to ace your .NET technical interview :: .Net Technical Check TuneupHow to ace your .NET technical interview :: .Net Technical Check Tuneup
How to ace your .NET technical interview :: .Net Technical Check Tuneup
 
.Net Debugging Techniques
.Net Debugging Techniques.Net Debugging Techniques
.Net Debugging Techniques
 
Sql Server Performance Tuning
Sql Server Performance TuningSql Server Performance Tuning
Sql Server Performance Tuning
 
Ssrs 2005 Reporting Services
Ssrs 2005 Reporting ServicesSsrs 2005 Reporting Services
Ssrs 2005 Reporting Services
 

Kürzlich hochgeladen

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Kürzlich hochgeladen (20)

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 

Serverless architectures: APIs, Serverless Functions, Microservices - How to get your product quickly to market?

  • 1. Welcome to the Manchester Community College, Manchester NH November 2, 2019
  • 2. @bsubra SERVERLESS COMPUTING APIS, SERVERLESS FUNCTIONS, MICROSERVICES - HOW TO GET YOUR PRODUCT QUICKLY TO MARKET?
  • 3. A BIG thank you to our 2019 Sponsors! Venue Sponsor Platinum Sponsor (Lunch & Refreshments) Diamond Sponsor (Lunch & iPad Raffle) Gold Sponsor (Speaker Appreciation) Silver Sponsor (Attendee Appreciation)
  • 4. Another BIG thank you to our in-kind sponsors! Raffle: Licenses Raffle: Meadow / Hack Kit Pro Chocolates Speaker / Schedule Management Raffle: Weekday Lift Tickets Raffle: Licenses
  • 7. @bsubra AGENDA • Why? • What? • How? - Demos • Architectures • EDA, Patterns, Best Practices • Advantages • Disadvantages • Next Steps
  • 10. @bsubra WHY? • Smallest Unit of Compute – Pure Code • Super, Hyper-Scalable • Rapid Iteration, CI, CD, Quickest Delivery • Extreme multi-tenancy • Very Polyglot friendly (Java, JS, C#, Python, Powershell, F#, Typescript, PHP, Go and so on) • Easier to Collaborate – Microservices, APIs • Deploy Independently – Go live to production in seconds
  • 11. @bsubra WHY? – FUTURE OF TECH INDUSTRY
  • 13. @bsubra MANDATORY VIEWING Source: IDC: Generating Value Through IT Agility & Business Scalability with Serverless Platform
  • 16. @bsubra WHAT? • Abstraction of backend infrastructure Completely • Execution environment for single purpose functions • Hosted in public cloud or on-premise • Serverless functions have a runtime in a stateless container • Node.JS, JavaScript, C#, Python, Java • Event-driven Startup Triggers / Instant Scale- out or Scale-in • Micro-billing instead of per-hour / per-month billing
  • 17. @bsubra AWS APPS - COMPARISON
  • 20. @bsubra MICROSERVICES ARCHITECTURE • Services can communicate via • through synchronous API requests (for example API Gateway) • through asynchronous messaging between services (for example SQS and SNS) • through a state machine orchestrator • State: Backend-as-a-Service (Baas): infrastructure components managed by a Cloud Provider • Google Cloud Firestore • Azure Storage / AWS S3 / Google Cloud Storage • CosmosDB / DynamoDB • Azure Kubernetes Service (AKS) • Google BigQuery
  • 22. @bsubra EVENT DRIVEN ARCHITECTURE (EDA) • Design Pattern around the Production and Reaction to Events • Serverless Functions are triggered by Events • Examples of Events • A File uploaded to an S3 bucket • Inserts on a DynamoDB Table • A Message published to an SNS topic – PubSub • A CloudWatch Alert • A message is available to read from a Kinesis stream
  • 23. @bsubra ADVANTAGES • Asynchronous, Concurrent • Infrequent or has Sporadic Demand • Stateless, Ephemeral • Highly Dynamic in terms of Changing Business Requirements
  • 24. @bsubra EXAMPLES OF SERVERLESS USE CASES • Multimedia processing • Database changes or Change Data Capture • IoT sensor input messages • Stream processing at scale • Chat bots • Batch jobs scheduled tasks • HTTP REST APIs and web apps • Mobile back ends • Business logic • Continuous integration pipeline Source: CNCF Serverless Whitepaper v1.0
  • 25. @bsubra TIPS AND TRICKS • Limit your Function Size (JVM Startup time especially) • Remember Execution is Async • Do not assume function container reuse but take advantage of it • Audit dependencies to keep bundle sizes small. • CloudWatch's default log retention period is forever. • Structure your logs to ease alert creation and debugging • Understand AWS account limits • Think twice before dynamically provisioning AWS resources. • Price - Is Serverless really as cheap as everyone claims? (dev.to) Unless you are operating at massive scale, serverless is not just cheap, it's a steal.
  • 26. @bsubra BEST PRACTICES • Scrutinize and research before attaching new input/event sources • Keep the functions’ permissions least privileged and maintain a least privileged build system • Amount of code that can access sensitive data be reduced, exceptions are handled and input is validated • Avoid embedding secrets and access keys in code • Do not store access keys or credentials in source code repositories • Throttle and define quotas on the amount of requests that go through • Keep data encrypted that is stored at rest • Scrutinize and keep tab on third party API services for vulnerabilities • Scan third party libraries for potential vulnerabilities and try to keep them up-to-date • Carefully examine granting permissions that allow creation, modification or removal of the resources
  • 28. @bsubra SERVERLESS FAILURE STORIES • Serverless out of control • Mo’ developers, mo’ problems: How serverless has trouble with teams • Beware “RunOnStartup” in Azure Functions – a serverless horror story • Serverless: A lesson learned. The hard way. • Serverless: 15% slower and 8x more expensive
  • 29. @bsubra DYNAMODB - BEST PRACTICES • Where it could be Used? • Wherever we see relationships… • Document management • Process control • Social network • Data trees • IT monitoring • Takeaways • NoSQL does not mean non-relational • The ERD still matters • RDBMS is not deprecated by NoSQL • Use NoSQL for OLTP or DSS at Scale. • Use RDBMS for OLAP or OLTP when Scale is not important.
  • 30. @bsubra DYNAMODB ANTI-PATTERNS • Prewritten application tied to a traditional relational database – If you are attempting to port an existing application to the AWS cloud and need to continue using a relational database, you may elect to use either Amazon RDS (Amazon Aurora, MySQL, PostgreSQL, Oracle, or SQL Server), or one of the many pre-configured Amazon EC2 database AMIs. You can also install your choice of database software on an EC2 instance that you manage. • Joins or complex transactions – While many solutions are able to leverage DynamoDB to support their users, it’s possible that your application may require joins, complex transactions, and other relational infrastructure provided by traditional database platforms. If this is the case, you may want to explore Amazon Redshift, Amazon RDS, or Amazon EC2 with a self-managed database. • Binary large objects (BLOB) data – If you plan on storing large (greater than 400 KB) BLOB data, such as digital video, images, or music, you’ll want to consider Amazon S3. However, DynamoDB still has a role to play in this scenario, for keeping track of metadata (e.g., item name, size, date created, owner, location, etc.) about your binary objects. • Large data with low I/O rate –DynamoDB uses SSD drives and is optimized for workloads with a high I/O rate per GB stored. If you plan to store very large amounts of data that are infrequently accessed, other storage options may be a better choice, such as Amazon S3.
  • 31. @bsubra LAMBDA - BEST PRACTICES • Minimize package size to necessities • Separate the Lambda handler from core logic • Read only what you need • Properly Indexed Databases • Query Filters in Aurora • Use S3 Select • Dynamic Logic via Configuration • Per Function - Use Environment Variables to modify operational behavior • Cross Function – Amazon Parameter Store / Secrets Manager • Self-contain dependencies in your function package • Leverage “Max Memory Used” to right-size your functions • Use Functions to TRANSORM (not for TRANSPORT) • Delete large unused functions (used to be 75GB limit)
  • 32. @bsubra LAMBDA – ANTI-PATTERNS • Long-running applications – Each Lambda function must complete within 300 seconds. For long-running applications that may require jobs to run longer than five minutes, Amazon EC2 is recommended or you create a chain of Lambda functions where function 1 calls function 2, which calls function 3, and so on until the process is completed. • Dynamic websites – While it is possible to run a static website with Lambda, running a highly dynamic and large volume website can be performance prohibitive. Using Amazon EC2 and Amazon CloudFront would be a recommended use case. • Stateful applications –Lambda code must be written in a “stateless” style; that is, it should assume there is no affinity to the underlying compute infrastructure. Local file system access, child processes, and similar artifacts may not extend beyond the lifetime of the request, and any persistent state should be stored in Amazon S3, DynamoDB, or another Internet-available storage service.
  • 36. @bsubra HOW AWS BUILT A PRODUCTION SERVICE USING SERVERLESS TECHNOLOGIES
  • 39. @bsubra HOW MATURE ARE YOU? - AUTOMATION
  • 40. @bsubra Features AWS Lambda Azure Functions Google Cloud Functions Language Support Node.js, Java, C#, Python Node.js, C#, F#, Python, PHP Node.js Security AWS IAM, VPC OAuth providers such as Azure Active Directory, Facebook, Google, Twitter, and Microsoft Account Cloud IAM Monitoring Cloudwatch Application Insights Stackdriver Monitoring Logging Cloudwatch Application Insights Analytics Stackdriver Logging Auditing CloudTrail Azure Audit Logs Cloud Audit Logging Alerts Cloudwatch Alarms Application Insights, Log Analytics, and Azure Monitor Stackdriver Monitoring Tooling Support CodePipeline, Code Build Azure Portal, Azure Powershell, Azure CLI, Azure SDK gcloud CLI for functions Debugging Support AWS X-Ray Azure CLI - local debugging, Azure App Service - remote debugging Stackdriver Debugger Pricing it depends Execution Time: $0.000016/GBs, 400,000 GBs/month are free Total Executions: $0.20/million executions, with 1 million executions/month free Invocations: $0.40/million invocations with 2 million invocations free Compute Time: $0.0000025/GBsec with 400,00 GB-sec/month free & $0.0000100/GHzsec with 200,000 GHz-sec/month free Limits Memory allocation range: Min. 128 MB / Max. 1536 MB (with 64 MB increments) Ephemeral disk capacity ("/tmp" space): 512 MB Number of file descriptors: 1,024 Number of processes and threads (combined total): 1,024 Maximum execution duration per request: 300 seconds Invoke request body payload size (RequestResponse): 6 MB Invoke request body payload size (Event): 128 K Invoke response body payload size (RequestResponse): 6 MB Allow only 10 concurrent executions per function No limitations on max. execution time limit Resource, Time and Rate Limits are defined under Google Cloud Functions Quota limits
  • 41. @bsubra DISADVANTAGES • Portability • Automation / DevOps • Cross-Cloud Communication • The Cold Start Problem • Applications that haven't been used recently take longer to startup and to handle the first request. • Because serverless happens on use, there aren’t dedicated instances ready to handle requests • Solution: Run a function in a dedicated container/VM, not serverless
  • 42. @bsubra DASHBOARD SHOWS LINK BETWEEN PERFORMANCE & COSTS
  • 44. @bsubra SECURITY RISKS 1. Function Event-Data Injection 2. Broken Authentication 3. Insecure Serverless Deployment Configuration 4. Overprivileged Function Permissions and Roles 5. Inadequate Function Monitoring and Logging 6. Insecure Third-Party Dependencies 7. Insecure Application Secrets Storage 8. Denial-of-Service and Financial Resource Exhaustion 9. Serverless Business Logic Manipulation 10. Improper Exception Handling and Verbose Error Messages 11. Legacy/Unused Functions & Cloud Resources 12. Cross-Execution Data Persistency Source: CSA - The 12 Most Critical Risks for Serverless Applications 2019
  • 46. @bsubra CONSIDERATIONS FOR THE ENTERPRISE • Cloud Silos • Enterprise Eventing • Serverless skills gap • Monitoring vs. Observability • Stateful vs. Stateless • Forecasting costs • Where serverless falls short Source: The New Stack Serverless Survey 2018 Q: What are the top three areas in which serverless falls short of expectations?
  • 47. @bsubra WORKS CITED • Serverless Architectures - Martin Fowler • Serverless on Google Cloud Platform: an Introduction with Serverless Store Demo • Introduction to Serverless: RISE Conference 2018 - Hong Kong Developer Workshop: Introduction to Serverless - Shaun Ray • Serverless is a Doctrine, not a Technology - Paul Johnston – Medium • The Serverless Sea Change • How AWS built a production service using serverless technologies | AWS Open Source Blog • Serverless Architectural Patterns and Best Practices | AWS Architecture Blog • Contemporary Views on Serverless and Implications - Subbu’s Blog @bsubra
  • 48. @bsubra SERVERLESS ON GOOGLE CLOUD PLATFORM • App Engine | Google Cloud • 1. Auth, Storage, Event Streaming, and Third-Party APIs (Firebase Authentication, Cloud Storage, Cloud Firestore, Cloud Pub/Sub and Third-Party APIs) • 11. Machine Learning, AI, Data Analytics, and Data Visualization (Cloud Vision API, Cloud AutoML, DialogFlow +Google Assistant integration, BigQuery and Data Studio) • 111. Serverless Computing, Management Tools, and Cron Jobs (App Engine, Cloud Functions, Cloud Scheduler, Stackdriver Logging, Stackdriver Monitoring, and Stackdriver Tracing) • 1111. Hacking Google Cloud Run
  • 49. @bsubra CALL TO ACTION 1. Write an AWS Lambda from Template • How do I get started with creating serverless applications? 2. Make your monolithic app use Step Functions 3. Try how Azure Kubernetes Service (AKS) can deploy your legacy apps 4. Make your next project be event driven with Azure Event Grid, or GCP Cloud Pub/Sub • Building a Reliable Serverless Application in a Weekend 5. Become familiar with application observability with comprehensive logging, metrics, and tracing 6. Follow folks pushing Serverless in twitter 7. Read a book • Serverless apps: Architecture, patterns, and Azure implementation | Microsoft Docs 8. Watch Videos like • AWS re:Invent: Accelerate Innovation & Maximize Business Value w/ Serverless Apps (SRV212-R1) • Keynote: Serverless, Not So FaaS - Kelsey Hightower, Kubernetes Community Member, Google

Hinweis der Redaktion

  1. APIs, Serverless Functions, Microservices - How to get your product quickly to market? Do you have the next best idea? How will you quickly migrate a legacy feature to new world for almost free? This talk will give you how to architect and implement your scenario for a cloud-oriented solution. We will share the best practices for storing your state in database; ways to decouple by events and suggested patterns for serverless. You will be equipped with taking advantage of low-cost serverless computing in a secure way and how to minimize operational costs. It will mostly focus AWS offerings like Serverless Aurora, API Gateway and Lambda functions for solutions blueprint.
  2. Balaji is a Boston-based developer, writer, speaker and debugger. He has expertise in infrastructure, internet technologies, and systems integration obtained through 20 plus years of working as a manager, architect and developer on projects for mission critical back end systems that have included various cloud platforms such as OpenStack, AWS and Azure. As a degreed Industrial engineer, he also has experience in distributive controls systems as a controls engineer at Honeywell. He has also worked extensively with global hedge fund industry providing SaaS solutions on the public cloud.
  3. An elderly couple had dinner at another couple's house, and after eating, the wives left the table and went into the kitchen. The two gentlemen were talking, and one said, 'Last night we went out to a new restaurant and it was really great. . . I would recommend it very highly.' The other man said, 'What is the name of the restaurant?' The first man thought and thought and finally said, 'What is the name of that flower you give to someone you love? You know... The one that's red and has thorns.' 'Do you mean a rose?' 'Yes, that's the one,' replied the man. He then turned towards the kitchen and yelled, 'Rose, what's the name of that restaurant we went to last night?'
  4. Development, debugging, deployment, delivery, and decommissioning of application services are the major portion of any application lifecycle management (ALM) process. This serverless deployment pattern recommends a kind of deployment infrastructure that hides the concept of servers (whether physical or virtual). The infrastructure takes the application service's code and runs it. The user has to pay for each of his requests based on the resources consumed. The performance, scalability, and availability requirements are being automatically met. Almost all the established cloud service providers are providing this new deployment pattern. This is a new cloud service ensuring every function is being delivered as a service.
  5. Serverless Can Help You To Focus - By Simona Cotin: Time is crucial in startups. We are experiencing a constant race against time. Your market might be time sensitive, and you need to grow fast. Most startups fail because they run out of cash and time. Serverless helps you spend time only on things that matter instead of stuff that seems shiny but isn’t essential. Two Uni Students From Queensland Built a Better Census Site in One Weekend - VICE: Their website is faster, cheaper, and more secure. And they didn't even fill out the Census this year. It cost the Australian Bureau of Statistics (ABS) many years and $9 million to build its somewhat inadequate Census website, which was taken down by a DDoS attack after being online for mere hours. Over the weekend, two uni students from Queensland were able to build a better Census site in two days for only $500. The two young computer geniuses behind the aptly-named Make Census Great Again website are students Austin Wilshire (18) and Bernd Hartzer (24). Both hail from the Queensland University of Technology. Their system can handle nearly 40 times as many census submissions per second as the ABS one can, and is specifically designed to prevent the DDoS attack that forced the Census offline on August 9.
  6. Intro to Serverless: A little bit of history, evolution, misconceptions around serverless Benefits: Get into why serverless, its benefits and characteristics Adoption: Insight into the adoption by enterprises and the tech community in general Architecture: Discussions around serverless architecture, FaaS, evolving patterns and solutions Security: Auth. services, access controls, surface areas for attack, data isolation... Development, Deployment & Testing: Rethinking around developing, deploying and testing serverless applications and services Toolsets: Evolving toolsets, frameworks and methodologies Changing DevOps: A look into the changing roles of DevOps teams and the Mindshift Challenges: Concerns around debugging, logging, and monitoring, of serverless applications Providers: A comparative look at the serverless providers out there Case Studies: Examples of real-life implementations of serverless technologies
  7. No server management Scales automatically Pay only while your code runs Runs code in response to events Open and familiar Connects and extends cloud services https://twitter.com/PaulDJohnston/status/1186908841100886017
  8. AMG Earnings Q3 19: The Future of the Tech Industry – Bernard Golden Last week all three of the most important cloud providers (I refer to them collectively as AMG — Amazon, Microsoft, and Google) announced their financial results. All continue to see impressive growth and, as a group, have achieved very significant results. The chart below indicates that the three are generated something like $16B or $17B for the quarter, although it’s impossible to be precise because Microsoft and Google do not break out their pure cloud computing revenues. The Leading Open Source Serverless Solutions for Kubernetes: The universe of serverless-wielding software architects and Kubernetes cluster operators has started to collide and, yet again, Google is in the driver's seat. In this article we'll wander down the CNCF's Serverless Landscape in chronological order, quickly discovering that Knative is the sweet mamba jamba of open source lambda competitors.
  9. 6 Strategies for Migrating Applications to the Cloud Rehosting — Otherwise known as “lift-and-shift.” Replatforming — I sometimes call this “lift-tinker-and-shift.” Repurchasing — Moving to a different product. Refactoring / Re-architecting — Re-imagining how the application is architected and developed, typically using cloud-native features. Retire — Get rid of. Retain — Usually this means “revisit” or do nothing (for now).
  10. Serverless computing promises a pay-as-you-go future with (almost) no server management at all. Serverless platforms take the code from developers and perform all the deployment tasks (networking, dependencies, maintenance, etc.) automatically behind the scenes
  11. https://twitter.com/kelseyhightower/status/1071512541690392576
  12. Serverless application Event Source Function Store Cloud Functions - Event-driven Serverless Computing  |  Cloud Functions  |  Google Cloud
  13. 1. Zero Administration: This is the most exciting thing about serverless. Whereas previous abstractions like VMs and containers still shared a lot of the same configuration and administration properties of servers, serverless is a completely different experience. When you're ready to deploy code, you don't have to provision anything beforehand, or manage anything afterward. There is no concept of a fleet, an instance, or even an operating system. Everything runs in the cloud and the provider manages scaling for you. 2. Pay-per-execution: This is what typically incentivizes developers to try serverless for the first time. It’s alluring to have complete resource utilization without paying a cent for idle time. This tenet alone results in over 90% cost-savings over a cloud VM and immeasurable developer satisfaction in knowing that you never have to pay for resources that you don’t use. 3. Function as unit of deployment: Serverless architectures are composed of very small, independent bits of code (functions) that are loosely coupled and collaborative—also known as a microservice architecture. The main advantage? Pieces of the system are contained. They can be developed and deployed independently. The result is fewer blockers and far greater developer autonomy and productivity. 4. Event-Driven: This aspect of serverless is the most under-the-radar right now, but is shaping up to be the most important in the long-term. Serverless functions are stateless, and essentially dormant, until they have an event to react to. The event is what brings them to life and provides them with the data/context to do their job. Event-driven architectures are nothing new, but the rise of serverless compute has renewed interest in them because serverless architectures are by definition event-driven. https://twitter.com/ben11kehoe/status/1097804380777205760
  14. Which serverless compute platform is right for you? https://cloud.google.com/serverless-options/
  15. https://twitter.com/kelseyhightower/status/1186832245664997377 Low barrier-to-entry Hostless Stateless Elasticity Distributed Event-driven
  16. AWS Step Functions enables us to construct a state machine graph with custom logic, where each processing node can be either AWS Lambda, AWS Batch or AWS Fargate. The Step Function service tracks the completion of the task as well as if an exception occurred. It enables us to branch out logic in case of error (with the ability to customize the handling of an error), execute jobs in parallel and implement retry logic. “clean architecture”, “hexagonal architecture” (ports and adapters), and “onion architecture”. Some argue it’s all the same.
  17. Serverless Event Sourcing in AWS (Lambda, DynamoDB, SQS): In this post, I have presented the project structured using Event Sourcing and CQRS patterns, written in TypeScript. The project I was building was a “Twitter-like” service  Source: Ajay Nair, Principal Product Manager (AWS Lambda) at Amazon Web Services (AWS) Event-driven architecture (EDA) is conceptually different than the client/server architecture most commonly used today All logic in an event-driven architecture is embodied in functions. Events trigger these functions and then the functions, in turn, trigger something downstream, which themselves may be functions, according to Ajay Nair, principal product manager for AWS Lambda at Amazon Web Services
  18. the infrastructure provisioning, setting up and administering time, and treasure and talent get reduced significantly. Software engineers can coolly focus on their core strengths without any botheration of the readying infrastructure to run their applications. Cost Elasticity versus scalability Productivity
  19. https://twitter.com/ShortJared/status/1100887501047132160 The job of a person in a business is not to provide technology, but to provide business value.
  20. Follow AWS Best Practices. The Lambda and Using Lambda with SQS Best Practices helps avoid Lambda throttles, understand SQS message batches (they succeed or fail together) and configure redrive policies high enough to prevent prematurely sending messages to dead-letter queues.
  21. A Common response to a recurring problem that is usually ineffective and risks being highly counterproductive
  22. https://github.com/cristim/serverless-failure-stories https://twitter.com/ajaynairthinks/status/1122197970743468033 Serverless and Microservices: a match made in heaven?: When the first tutorials started to come out using AWS Lambda and API Gateway, back in 2015, it was unsurprising to find that they focused largely on replicating the microservice. However, it…
  23. Tenets of NoSQL Data Modeling Understand the use case Nature of the application  OLTP / OLAP / DSS  Define the Entity-Relationship Model  Identify Data Life Cycle  TTL, Backup/Archival, etc Identify the access patterns Identify data sources  Define query aggregations  Document all workflows Read/Write workloads  Query dimensions and aggregations  Data-modeling  Avoid relational design patterns, use one table  1 application service = 1 table  Reduce round trips  Simplify access patterns  Identify Primary Keys  How will items be inserted and read?  Overload items into partitions  Define indexes for secondary access patterns Review -> Repeat -> Review 
  24. Amazon DynamoDB helps you build serverless applications by providing a managed NoSQL database for persistent storage. Combined with DynamoDB Streams you can respond in near real-time to changes in your DynamoDB table by invoking Lambda functions.  DynamoDB Accelerator (DAX) adds a highly available in-memory cache for DynamoDB that delivers up to 10x performance improvement from milliseconds to microseconds.
  25. Exposed AWS Lambda Functions: Identify any publicly accessible AWS Lambda functions and update their access policy in order to protect against unauthorized users that are sending requests to invoke these functions Allowing anonymous users to invoke your Amazon Lambda functions is considered bad practice and can lead to data exposure, data loss and unexpected charges on your AWS bill. To prevent any unauthorized invocation requests to your Lambda functions, restrict access only to trusted entities Lambda Functions with Admin Privileges AWS Lambda Unknown Cross Account Access Lambda Runtime Environment Version Using An IAM Role For More Than One Lambda Function Tracing Enabled
  26. Orchestrate your application with state machines, not functions: Chaining Lambda executions within the code to orchestrate the workflow of your application results in a monolithic and tightly coupled application. Instead, use a state machine to orchestrate transactions and communication flows. AWS Serverless Application Model (AWS SAM) is an extension of AWS CloudFormation that is used to package, test, and deploy serverless applications. SAM Local can also enable faster debugging cycles when developing Lambda functions locally. AWS Step Functions orchestrates serverless workflows including coordination, state, and function chaining as well as combining long-running executions not supported within Lambda execution limits by breaking into multiple steps or by calling workers running on Amazon Elastic Compute Cloud (Amazon EC2) instances or on-premises: Applying the Saga pattern with AWS Lambda and Step Functions | theburningmonk.com With Amazon API Gateway, you can run a fully managed REST API that integrates with Lambda to execute your business logic and includes traffic management, authorization and access control, monitoring, and API versioning: Error Handling Patterns in Amazon API Gateway and AWS Lambda | AWS Compute Blog Accessing Amazon CloudWatch Logs for AWS Lambda - AWS Lambda A Simple Serverless Test Harness using AWS Lambda | AWS Compute Blog AWS Lambda Function Versioning and Aliases - AWS Lambda Environment Variables - AWS Lambda AWS Lambda and AWS X-Ray - AWS X-Ray Dead Letter Queues  (DLQ) - AWS Lambda Understanding Container Reuse in AWS Lambda | AWS Compute Blog
  27. Serverless web application - Azure Reference Architectures | Microsoft Docs: Recommended architecture for a serverless web application and web API. Azure Serverless | Microsoft Azure 1 User accesses the web app in browser and signs in. 2 Browser pulls static resources such as images from Azure Content Delivery Network. 3 User searches for products and queries SQL database. 4 Web site pulls product catalog from database. 5 Web app pulls product images from Blob Storage. 6 Page output is cached in Azure Cache for Redis for better performance. 7 User submits order and order is placed in the queue. 8 Azure Functions processes order payment. 9 Azure Functions makes payment to third party and records payment in SQL database.
  28. AWS - Multiple points to optimize - Invocations, Functions, Interactions AWS Batch and AWS Fargate: why they are beneficial and what their differences are. AWS Step Functions: how it is different from other ways of connecting services and what the advantages are. What are some specific cases where hybrid infrastructure could be beneficial
  29. Build a real-life serverless app with AWS Amplify last year’s Re:Invent deep-dive video on DynamoDB
  30. open source project designed to help customers learn from Amazon’s approach to building serverless applications. The project captures key architectural components, code structure, deployment techniques, testing approaches, and operational practices of the AWS Serverless Application Repository, a production-grade AWS service written mainly in Java and built using serverless technologies.  available in the project wiki.
  31. Further Discussions for some tips and notes about Serverless Store. part of the Serverless on Google Cloud Platform: an Introduction with Serverless Store Demo How-to Guide. It discusses the authentication, storage, event streaming solutions, and third-party APIs Serverless Store uses.
  32. It is only suitable for deploying stateless applications that run quickly and respond to requests. Running long-running stateful applications such as a database or message broker in the serverless model is not possible. If an application takes a long time to start, then the application is not a good fit for serverless deployment. Similarly, legacy monolithic and massive applications are not suitable for serverless computing. Serverless deployment is typically reactive, not proactive, and hence the issue of high latency can arise https://twitter.com/jessfraz/status/942031487809085440
  33. On the face of it, it would appear that choosing the lowest memory allocation for compute would be the cheapest. But that’s not always the case. Execution time may lengthen with smaller memory size allocations, thus raising the overall cost, the company also used Amazon’s CloudWatch tools, which turned out to be surprisingly costly. But perhaps the biggest hidden cost comes from API requests. when a bug in its CloudWatch function prevented the service from scaling well. They discovered that 5,000 functions were repeatedly getting timeouts that amounted to a cost of $12,000 per month — a fortune for a small startup. Cloud providers do, thankfully, offer the ability to set rate limits and spending thresholds on service accounts and will issue automatic billing alerts if you reach your limits. But closely monitoring risks associated with spiking and ensuring that estimated costs will not jump from poor performance of serverless workflows and systems will be a focus in the coming year
  34. LambdaGuard - tool which allows you to visualize and audit the security of your serverless assets, an open-source AWS Lambda Serverless Security Scanner. https://darknet.org.uk/2019/10/lambdaguard-aws-lambda-serverless-security-scanner/… via @THEdarknet statistical analysis AWS service dependencies configuration checks
  35. AWS Lambda automatically monitors Lambda functions on your behalf. Through Amazon CloudWatch, it reports metrics such as the number of requests, the execution duration per request, and the number of requests resulting in an error. These metrics are exposed at the function level, which you can then leverage to set CloudWatch alarms. Using Amazon CloudTrail, you can implement governance, compliance, operational auditing, and risk auditing of your entire AWS account, including Lambda. CloudTrail enables you to log, continuously monitor, and retain account activity related to actions across your AWS infrastructure, providing a complete event history of actions taken through the AWS Management Console, AWS SDKs, command line tools, and other AWS services. Using CloudTrail, you can optionally encrypt the log files using Amazon Key Management Service (KMS) and also leverage the CloudTrail log file integrity validation for positive assertion. Using AWS X-Ray, you can analyze and debug production and distributed Lambda-based applications, which enables you to understand the performance of your application and its underlying services, so you can eventually identify and troubleshoot the root cause of performance issues and errors. X-Ray’s end-to-end view of requests as they travel through your application shows a map of the application’s underlying components, so you can analyze applications during development and in production. With AWS Config, you can track configuration changes to the Lambda functions (including deleted functions), runtime environments, tags, handler name, code size, memory allocation, timeout settings, and concurrency settings, along with Lambda IAM execution role, subnet, and security group associations. This gives you a holistic view of the Lambda function’s lifecycle and enables you to surface that data for potential audit and compliance requirements
  36. Whole-Event Serverless Observability - IOpipe Blog The Serverless Vector Map Stack Lives! - Alexander Rolek - Medium: TL;DR: With the release of AWS Aurora Serverless Postgres (with PostGIS support), building an entirely serverless map stack is now possible, including the database.  How to FaaS like a pro: 12 less common ways to invoke your serverless functions on AWS
  37. Cloud Functions - Event-driven Serverless Computing  |  Cloud Functions  |  Google Cloud Performance Resource limits Monitoring and debugging Security Privacy Standards Vendor lock-in
  38. Watch Google Global Digital Conference 2019. Watch more #io19 here: GCP at Google I/O 2019 Playlist → https://goo.gle/2ZPLejw Google I/O 2019 All Sessions Playlist → https://goo.gle/io19allsessions Learn more on the I/O Website → https://google.com/io Google Cloud Platform Channel → https://goo.gle/GCP Get started at → https://cloud.google.com/gcp
  39. When you’re building serverless applications on AWS, you can use AWS CloudFormation directly, or choose the AWS Serverless Application Model, also known as AWS SAM.  Introduction to Serverless Building large scale applications with AWS Lambda Building Enterprise-Grade Serverless Applications Best Practices for Optimizing your Data Lake with AWS Serverless Real-Time Streaming Analytics and Machine Learning in Serverless Era Serverless Development, CI/CD  Serverless database for your Serverless App Serverless intelligence - the fastest path to smart applications