SlideShare a Scribd company logo
1 of 70
Download to read offline
FaaS You Like It
(If Shakespeare had written
Functions as a Service)
“All the world’s a stage, And all the men and women
merely players; They have their exits and their entrances,
And one man in his time plays many parts…”
Cast
Cloud Architect - Ewan Slater
Agenda
1. What is FaaS (or “Serverless”)
2. The Fn Project
3. FDKs
4. As you like it - performed by Fn functions, written in Ruby & Java
Synopsis
“As You Like It subverts the traditional rules of romance.
Gender roles, nature and politics are confused in a play that
reflects on how bewildering yet utterly pleasurable life can
be.”
- Royal Shakespeare Company
Bewilderment:
Why dost thy Serverless Architecture have
so many servers?
Soliloquy
<Grumpy-Old-Man-Moment>
There are only two hard things in Computer
Science: cache invalidation and naming
things.
- Phil Karlton
I don’t like “Serverless” as a name
● Hidden Servers
● Transient Servers
● Abstracted Infrastructure
● Anything really
"For everyone's sake, someone
please come up with a better
name than serverless”
- Simon Wardley
</Grumpy-Old-Man-Moment>
Suspension of Disbelief
“The Play’s the thing…”
Actor learns own part
● Cues (input)
● Lines (output)
● Stage Directions (state)
Actor ⇒ Function
Single responsibility
Audience care about action
Not what happens backstage
Business doesn’t care about
infrastructure
FaaS: action not infrastructure
Increase developer
Productivity
by adding another layer of
Abstraction
(a recurring theme)
FaaS
● Write small functions
● Do one thing well
● Easy to Understand
● Easy to Maintain
● Run on Abstracted Infrastructure (“Serverless”) platform
Avoid
What is “Serverless”?
● Serverless is an abstraction of infrastructure and its operations including
provisioning, scaling, patching, etc.
● Serverless architecture is when an app is built entirely on serverless
components (compute, storage, networking)
● Function as a Service (FaaS) is the compute component in a serverless
architecture
For a fuller discussion...
Mike Roberts article on MartinFowler.com
https://martinfowler.com/articles/serverless.html
“Fundamentally, FaaS is about running backend code without managing
your own server systems or your own long-lived server applications.”
From Microservices to Functions
Granularity
Scale
Time
PaaS vs FaaS
● Granularity, Scale & Time
○ Paas (or IaaS) ⇒ (Micro)Service, long - running
○ FaaS ⇒ Function, invoked on demand
If your PaaS can efficiently start instances in 20ms that run for half a
second, then call it serverless.
- Adrian Cockcroft
Functions != Functional
● Functions can have side effects
● Functions don’t have to be idempotent
FaaS Upsides
● Make development easier
● Improve developer productivity
● Increased agility (Dev & Business)
● Reduce costs (Dev & Operations)
FaaS Downsides
● “ball of mud”
● Lock - in
● Restricted choice
○ Language
○ Run - time environment
Language Support
● AWS
○ Node, Python, Java, C#, Go
● Google
○ Node
● Azure
○ C#, JavaScript, F#, (Java - preview)
“Gadzooks! No Ruby?”
(Or Erlang, or Rust, or FORTRAN etc.)
Choice:
Write your functions in any language.
Run them in any environment.
Fn Project:
Write your functions in any language*.
Run them in any environment*.
*Supports / supported by Docker
Fn Project ( fnproject.io )
● Open-source serverless compute platform
● Can be deployed to any cloud or on-premises
● Containers are primitives
● Active w/ 2500+ commits across 50+ contributors
● Independently governed with representation at CNCF
● support for the upcoming CloudEvents specification
○ (CNCF Serverless working group )
● integration with the Serverless Framework toolkit
Functions as Containers
● Function and dependencies
● Single - purpose
● Self - Contained
● Stateless
● Ephemeral
● Run on Demand
An Fn Function
● Small chunk of code wrapped into container
● Input from STDIN & Environment
● Output to STDOUT
● Logs to STDERR
Fn deploy details
● Bump version in func.yaml
● Build container (multi stage)
● Push container to registry
● Create / Update function route
MyFunc:0.0.2
MyFunc:0.0.2 MyFunc:0.0.2
Your code
Fn Service
myfunc →
/r/myapp/myfunc:0.0.2
1 2 3
Fn Server
● “API Gateway”
● Manages apps and functions
○ (app ⇒ group of functions)
● Synchronous function calls
○ Executed immediately
● Asynchronous function calls
○ Queued and executed when capacity available
● Runs as a Container
● Hosts function containers using Docker - in - Docker
Docker in Docker
● Limited “blast radius”
○ Doesn’t affect outer VM
○ Kill Fn container & restart
● Docker version independence
○ (inner can differ from outer)
● Reduce chance of container name collisions
Architecture
Hot and Cold
● Cold Functions
○ Run once only
○ Terminate immediately
○ New container every invocation
● Hot Functions
○ Run at least once
○ Wait before terminating
○ Potentially reusable
Synchronous Request
Asynchronous Request
Function Development Kits (FDKs)
● Developer writes a handler function to the FDKs interface
● FDK
○ Parses STDIN
○ Provides input data to function
○ Handles writing output and errors
○ Manages multiple invocations
● Makes it a lot easier to write hot functions
FDKs
● Ruby ( https://github.com/fnproject/fdk-ruby )
● Others
○ Python
○ Go
○ Java
○ Node
○ Rust
○ ...more on the way...
Without an FDK
● Dockerfile
● func.yaml
● func.* (e.g. func.sh)
● DIY
Orchestration
Flow
● Promises based Orchestration
○ No new “special” language
○ Composable
○ Flexible
○ Supports “Saga Pattern”
● A Flow is...
○ ...written in Code
○ ...written as Function
○ ...deployed as a function (within an application)
Flow
● Language Support:
○ Java
○ Python
○ Node
● In the works:
○ Go
● To - do:
○ Ruby
As You Like It
bitbucket.org/ewan_slater/comedy/src/master/
Summary
● FaaS ⇒ Greater developer productivity
● Fn Project ⇒ FaaS Framework
○ Open Source
○ Portable
○ Language Agnostic
○ Multiple FDKs
● Feedback and contributions welcome!
Links & Contact
● Fn Project ( fnproject.io )
○ github.com/fnproject
○ Slack
● Twitter
○ Fn Project: @fnproj
○ Me: @ewanslater
Proceed, proceed: we will begin these rites,
As we do trust they'll end, in true delights.
(all exit to the pub)

More Related Content

What's hot

Developing high-performance network servers in Lisp
Developing high-performance network servers in LispDeveloping high-performance network servers in Lisp
Developing high-performance network servers in LispVladimir Sedach
 
Lisp Meet Up #31, Clake: a GNU make-like build utility in Common Lisp
Lisp Meet Up #31, Clake: a GNU make-like build utility in Common LispLisp Meet Up #31, Clake: a GNU make-like build utility in Common Lisp
Lisp Meet Up #31, Clake: a GNU make-like build utility in Common Lispmasayukitakagi
 
Jslab rssh: JS as language platform
Jslab rssh:  JS as language platformJslab rssh:  JS as language platform
Jslab rssh: JS as language platformRuslan Shevchenko
 
Ruby eventmachine pres at rubybdx
Ruby eventmachine pres at rubybdxRuby eventmachine pres at rubybdx
Ruby eventmachine pres at rubybdxMathieu Elie
 
GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話
GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話
GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話なおき きしだ
 
GeoDistributed datacenter: the DNS way
GeoDistributed datacenter: the DNS wayGeoDistributed datacenter: the DNS way
GeoDistributed datacenter: the DNS wayMoyd.co LTD
 
My talk at Linux Piter 2015
My talk at Linux Piter 2015My talk at Linux Piter 2015
My talk at Linux Piter 2015Alex Chistyakov
 
Taming Pythons with ZooKeeper (Pyconfi edition)
Taming Pythons with ZooKeeper (Pyconfi edition)Taming Pythons with ZooKeeper (Pyconfi edition)
Taming Pythons with ZooKeeper (Pyconfi edition)Jyrki Pulliainen
 
fluent-plugin-beats at Elasticsearch meetup #14
fluent-plugin-beats at Elasticsearch meetup #14fluent-plugin-beats at Elasticsearch meetup #14
fluent-plugin-beats at Elasticsearch meetup #14N Masahiro
 
4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki
4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki
4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian GrodzickiPROIDEA
 
Run C++ as serverless with GCP Cloud Functions
Run C++ as serverless with GCP Cloud FunctionsRun C++ as serverless with GCP Cloud Functions
Run C++ as serverless with GCP Cloud FunctionsRuncy Oommen
 
Openshift GeoSpatial Capabilities
Openshift GeoSpatial CapabilitiesOpenshift GeoSpatial Capabilities
Openshift GeoSpatial CapabilitiesSteven Pousty
 
HTTP::Parser::XS - writing a fast & secure XS module
HTTP::Parser::XS - writing a fast & secure XS moduleHTTP::Parser::XS - writing a fast & secure XS module
HTTP::Parser::XS - writing a fast & secure XS moduleKazuho Oku
 
Dockerizing Rails
Dockerizing RailsDockerizing Rails
Dockerizing RailsiGbanam
 
Ruby in office time reboot
Ruby in office time rebootRuby in office time reboot
Ruby in office time rebootKentaro Goto
 

What's hot (20)

Developing high-performance network servers in Lisp
Developing high-performance network servers in LispDeveloping high-performance network servers in Lisp
Developing high-performance network servers in Lisp
 
Lisp Meet Up #31, Clake: a GNU make-like build utility in Common Lisp
Lisp Meet Up #31, Clake: a GNU make-like build utility in Common LispLisp Meet Up #31, Clake: a GNU make-like build utility in Common Lisp
Lisp Meet Up #31, Clake: a GNU make-like build utility in Common Lisp
 
Lisp in the Cloud
Lisp in the CloudLisp in the Cloud
Lisp in the Cloud
 
Jslab rssh: JS as language platform
Jslab rssh:  JS as language platformJslab rssh:  JS as language platform
Jslab rssh: JS as language platform
 
Ruby eventmachine pres at rubybdx
Ruby eventmachine pres at rubybdxRuby eventmachine pres at rubybdx
Ruby eventmachine pres at rubybdx
 
GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話
GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話
GraalVMの紹介とTruffleでPHPぽい言語を実装したら爆速だった話
 
Git introduction
Git introductionGit introduction
Git introduction
 
Initiation à Ruby on Rails
Initiation à Ruby on RailsInitiation à Ruby on Rails
Initiation à Ruby on Rails
 
GeoDistributed datacenter: the DNS way
GeoDistributed datacenter: the DNS wayGeoDistributed datacenter: the DNS way
GeoDistributed datacenter: the DNS way
 
IDLs
IDLsIDLs
IDLs
 
My talk at Linux Piter 2015
My talk at Linux Piter 2015My talk at Linux Piter 2015
My talk at Linux Piter 2015
 
Taming Pythons with ZooKeeper (Pyconfi edition)
Taming Pythons with ZooKeeper (Pyconfi edition)Taming Pythons with ZooKeeper (Pyconfi edition)
Taming Pythons with ZooKeeper (Pyconfi edition)
 
fluent-plugin-beats at Elasticsearch meetup #14
fluent-plugin-beats at Elasticsearch meetup #14fluent-plugin-beats at Elasticsearch meetup #14
fluent-plugin-beats at Elasticsearch meetup #14
 
4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki
4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki
4Developers 2015: Scaling LAMP doesn't have to suck - Sebastian Grodzicki
 
Run C++ as serverless with GCP Cloud Functions
Run C++ as serverless with GCP Cloud FunctionsRun C++ as serverless with GCP Cloud Functions
Run C++ as serverless with GCP Cloud Functions
 
Openshift GeoSpatial Capabilities
Openshift GeoSpatial CapabilitiesOpenshift GeoSpatial Capabilities
Openshift GeoSpatial Capabilities
 
Docker and stuff
Docker and stuffDocker and stuff
Docker and stuff
 
HTTP::Parser::XS - writing a fast & secure XS module
HTTP::Parser::XS - writing a fast & secure XS moduleHTTP::Parser::XS - writing a fast & secure XS module
HTTP::Parser::XS - writing a fast & secure XS module
 
Dockerizing Rails
Dockerizing RailsDockerizing Rails
Dockerizing Rails
 
Ruby in office time reboot
Ruby in office time rebootRuby in office time reboot
Ruby in office time reboot
 

Similar to FaaS you like it (if Shakespeare had written Functions-as-a-Service)

A Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersA Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersDocker, Inc.
 
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special EditionIntroduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special EditionJérôme Petazzoni
 
Docker 0.11 at MaxCDN meetup in Los Angeles
Docker 0.11 at MaxCDN meetup in Los AngelesDocker 0.11 at MaxCDN meetup in Los Angeles
Docker 0.11 at MaxCDN meetup in Los AngelesJérôme Petazzoni
 
Erlang - Concurrent Language for Concurrent World
Erlang - Concurrent Language for Concurrent WorldErlang - Concurrent Language for Concurrent World
Erlang - Concurrent Language for Concurrent WorldZvi Avraham
 
"Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo...
"Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo..."Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo...
"Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo...Yandex
 
Introduction to Docker (and a bit more) at LSPE meetup Sunnyvale
Introduction to Docker (and a bit more) at LSPE meetup SunnyvaleIntroduction to Docker (and a bit more) at LSPE meetup Sunnyvale
Introduction to Docker (and a bit more) at LSPE meetup SunnyvaleJérôme Petazzoni
 
FITC - Node.js 101
FITC - Node.js 101FITC - Node.js 101
FITC - Node.js 101Rami Sayar
 
Free the Functions with Fn project!
Free the Functions with Fn project!Free the Functions with Fn project!
Free the Functions with Fn project!J On The Beach
 
Docker for local development
Docker for local developmentDocker for local development
Docker for local developmentAdam Štipák
 
Let's Containerize New York with Docker!
Let's Containerize New York with Docker!Let's Containerize New York with Docker!
Let's Containerize New York with Docker!Jérôme Petazzoni
 
Docker Intro at the Google Developer Group and Google Cloud Platform Meet Up
Docker Intro at the Google Developer Group and Google Cloud Platform Meet UpDocker Intro at the Google Developer Group and Google Cloud Platform Meet Up
Docker Intro at the Google Developer Group and Google Cloud Platform Meet UpJérôme Petazzoni
 
Improving Development and Deployment with Docker
Improving Development and Deployment with DockerImproving Development and Deployment with Docker
Improving Development and Deployment with DockerIrfad Razick
 
Lightweight Virtualization with Linux Containers and Docker | YaC 2013
Lightweight Virtualization with Linux Containers and Docker | YaC 2013Lightweight Virtualization with Linux Containers and Docker | YaC 2013
Lightweight Virtualization with Linux Containers and Docker | YaC 2013dotCloud
 
Lightweight Virtualization with Linux Containers and Docker I YaC 2013
Lightweight Virtualization with Linux Containers and Docker I YaC 2013Lightweight Virtualization with Linux Containers and Docker I YaC 2013
Lightweight Virtualization with Linux Containers and Docker I YaC 2013Docker, Inc.
 
Workshop : 45 minutes pour comprendre Docker avec Jérôme Petazzoni
Workshop : 45 minutes pour comprendre Docker avec Jérôme PetazzoniWorkshop : 45 minutes pour comprendre Docker avec Jérôme Petazzoni
Workshop : 45 minutes pour comprendre Docker avec Jérôme PetazzoniTheFamily
 
Introduction to Docker, December 2014 "Tour de France" Edition
Introduction to Docker, December 2014 "Tour de France" EditionIntroduction to Docker, December 2014 "Tour de France" Edition
Introduction to Docker, December 2014 "Tour de France" EditionJérôme Petazzoni
 
LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013dotCloud
 
LXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software DeliveryLXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software DeliveryDocker, Inc.
 

Similar to FaaS you like it (if Shakespeare had written Functions-as-a-Service) (20)

A Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and ContainersA Gentle Introduction to Docker and Containers
A Gentle Introduction to Docker and Containers
 
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special EditionIntroduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
Introduction to Docker, December 2014 "Tour de France" Bordeaux Special Edition
 
Docker 0.11 at MaxCDN meetup in Los Angeles
Docker 0.11 at MaxCDN meetup in Los AngelesDocker 0.11 at MaxCDN meetup in Los Angeles
Docker 0.11 at MaxCDN meetup in Los Angeles
 
Erlang - Concurrent Language for Concurrent World
Erlang - Concurrent Language for Concurrent WorldErlang - Concurrent Language for Concurrent World
Erlang - Concurrent Language for Concurrent World
 
"Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo...
"Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo..."Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo...
"Lightweight Virtualization with Linux Containers and Docker". Jerome Petazzo...
 
Introduction to Docker (and a bit more) at LSPE meetup Sunnyvale
Introduction to Docker (and a bit more) at LSPE meetup SunnyvaleIntroduction to Docker (and a bit more) at LSPE meetup Sunnyvale
Introduction to Docker (and a bit more) at LSPE meetup Sunnyvale
 
FITC - Node.js 101
FITC - Node.js 101FITC - Node.js 101
FITC - Node.js 101
 
Free the Functions with Fn project!
Free the Functions with Fn project!Free the Functions with Fn project!
Free the Functions with Fn project!
 
Docker for local development
Docker for local developmentDocker for local development
Docker for local development
 
Realtime web2012
Realtime web2012Realtime web2012
Realtime web2012
 
Let's Containerize New York with Docker!
Let's Containerize New York with Docker!Let's Containerize New York with Docker!
Let's Containerize New York with Docker!
 
Docker Intro at the Google Developer Group and Google Cloud Platform Meet Up
Docker Intro at the Google Developer Group and Google Cloud Platform Meet UpDocker Intro at the Google Developer Group and Google Cloud Platform Meet Up
Docker Intro at the Google Developer Group and Google Cloud Platform Meet Up
 
The Obsoletion of the OS
The Obsoletion of the OSThe Obsoletion of the OS
The Obsoletion of the OS
 
Improving Development and Deployment with Docker
Improving Development and Deployment with DockerImproving Development and Deployment with Docker
Improving Development and Deployment with Docker
 
Lightweight Virtualization with Linux Containers and Docker | YaC 2013
Lightweight Virtualization with Linux Containers and Docker | YaC 2013Lightweight Virtualization with Linux Containers and Docker | YaC 2013
Lightweight Virtualization with Linux Containers and Docker | YaC 2013
 
Lightweight Virtualization with Linux Containers and Docker I YaC 2013
Lightweight Virtualization with Linux Containers and Docker I YaC 2013Lightweight Virtualization with Linux Containers and Docker I YaC 2013
Lightweight Virtualization with Linux Containers and Docker I YaC 2013
 
Workshop : 45 minutes pour comprendre Docker avec Jérôme Petazzoni
Workshop : 45 minutes pour comprendre Docker avec Jérôme PetazzoniWorkshop : 45 minutes pour comprendre Docker avec Jérôme Petazzoni
Workshop : 45 minutes pour comprendre Docker avec Jérôme Petazzoni
 
Introduction to Docker, December 2014 "Tour de France" Edition
Introduction to Docker, December 2014 "Tour de France" EditionIntroduction to Docker, December 2014 "Tour de France" Edition
Introduction to Docker, December 2014 "Tour de France" Edition
 
LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013
 
LXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software DeliveryLXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software Delivery
 

Recently uploaded

Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...Christina Lin
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataBradBedford3
 
What is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWhat is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWave PLM
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software DevelopersVinodh Ram
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - InfographicHr365.us smith
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about usDynamic Netsoft
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfPower Karaoke
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...aditisharan08
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptkotipi9215
 

Recently uploaded (20)

Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer DataAdobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
Adobe Marketo Engage Deep Dives: Using Webhooks to Transfer Data
 
What is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWhat is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need It
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software Developers
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
Asset Management Software - Infographic
Asset Management Software - InfographicAsset Management Software - Infographic
Asset Management Software - Infographic
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about us
 
The Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdfThe Evolution of Karaoke From Analog to App.pdf
The Evolution of Karaoke From Analog to App.pdf
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.ppt
 

FaaS you like it (if Shakespeare had written Functions-as-a-Service)

  • 1. FaaS You Like It (If Shakespeare had written Functions as a Service)
  • 2. “All the world’s a stage, And all the men and women merely players; They have their exits and their entrances, And one man in his time plays many parts…”
  • 4. Agenda 1. What is FaaS (or “Serverless”) 2. The Fn Project 3. FDKs 4. As you like it - performed by Fn functions, written in Ruby & Java
  • 5. Synopsis “As You Like It subverts the traditional rules of romance. Gender roles, nature and politics are confused in a play that reflects on how bewildering yet utterly pleasurable life can be.” - Royal Shakespeare Company
  • 6. Bewilderment: Why dost thy Serverless Architecture have so many servers?
  • 7.
  • 9. There are only two hard things in Computer Science: cache invalidation and naming things. - Phil Karlton
  • 10. I don’t like “Serverless” as a name ● Hidden Servers ● Transient Servers ● Abstracted Infrastructure ● Anything really
  • 11. "For everyone's sake, someone please come up with a better name than serverless” - Simon Wardley
  • 14. “The Play’s the thing…”
  • 15. Actor learns own part ● Cues (input) ● Lines (output) ● Stage Directions (state)
  • 19. Not what happens backstage
  • 20. Business doesn’t care about infrastructure
  • 21. FaaS: action not infrastructure
  • 22. Increase developer Productivity by adding another layer of Abstraction
  • 24. FaaS ● Write small functions ● Do one thing well ● Easy to Understand ● Easy to Maintain ● Run on Abstracted Infrastructure (“Serverless”) platform
  • 25. Avoid
  • 26. What is “Serverless”? ● Serverless is an abstraction of infrastructure and its operations including provisioning, scaling, patching, etc. ● Serverless architecture is when an app is built entirely on serverless components (compute, storage, networking) ● Function as a Service (FaaS) is the compute component in a serverless architecture
  • 27. For a fuller discussion... Mike Roberts article on MartinFowler.com https://martinfowler.com/articles/serverless.html “Fundamentally, FaaS is about running backend code without managing your own server systems or your own long-lived server applications.”
  • 30. Scale
  • 31. Time
  • 32. PaaS vs FaaS ● Granularity, Scale & Time ○ Paas (or IaaS) ⇒ (Micro)Service, long - running ○ FaaS ⇒ Function, invoked on demand If your PaaS can efficiently start instances in 20ms that run for half a second, then call it serverless. - Adrian Cockcroft
  • 33. Functions != Functional ● Functions can have side effects ● Functions don’t have to be idempotent
  • 34. FaaS Upsides ● Make development easier ● Improve developer productivity ● Increased agility (Dev & Business) ● Reduce costs (Dev & Operations)
  • 35. FaaS Downsides ● “ball of mud” ● Lock - in ● Restricted choice ○ Language ○ Run - time environment
  • 36. Language Support ● AWS ○ Node, Python, Java, C#, Go ● Google ○ Node ● Azure ○ C#, JavaScript, F#, (Java - preview)
  • 38. (Or Erlang, or Rust, or FORTRAN etc.)
  • 39. Choice: Write your functions in any language. Run them in any environment.
  • 40. Fn Project: Write your functions in any language*. Run them in any environment*. *Supports / supported by Docker
  • 41. Fn Project ( fnproject.io ) ● Open-source serverless compute platform ● Can be deployed to any cloud or on-premises ● Containers are primitives ● Active w/ 2500+ commits across 50+ contributors ● Independently governed with representation at CNCF ● support for the upcoming CloudEvents specification ○ (CNCF Serverless working group ) ● integration with the Serverless Framework toolkit
  • 42. Functions as Containers ● Function and dependencies ● Single - purpose ● Self - Contained ● Stateless ● Ephemeral ● Run on Demand
  • 43. An Fn Function ● Small chunk of code wrapped into container ● Input from STDIN & Environment ● Output to STDOUT ● Logs to STDERR
  • 44.
  • 45.
  • 46.
  • 47.
  • 48.
  • 49.
  • 50.
  • 51.
  • 52. Fn deploy details ● Bump version in func.yaml ● Build container (multi stage) ● Push container to registry ● Create / Update function route MyFunc:0.0.2 MyFunc:0.0.2 MyFunc:0.0.2 Your code Fn Service myfunc → /r/myapp/myfunc:0.0.2 1 2 3
  • 53.
  • 54. Fn Server ● “API Gateway” ● Manages apps and functions ○ (app ⇒ group of functions) ● Synchronous function calls ○ Executed immediately ● Asynchronous function calls ○ Queued and executed when capacity available ● Runs as a Container ● Hosts function containers using Docker - in - Docker
  • 55. Docker in Docker ● Limited “blast radius” ○ Doesn’t affect outer VM ○ Kill Fn container & restart ● Docker version independence ○ (inner can differ from outer) ● Reduce chance of container name collisions
  • 57. Hot and Cold ● Cold Functions ○ Run once only ○ Terminate immediately ○ New container every invocation ● Hot Functions ○ Run at least once ○ Wait before terminating ○ Potentially reusable
  • 60. Function Development Kits (FDKs) ● Developer writes a handler function to the FDKs interface ● FDK ○ Parses STDIN ○ Provides input data to function ○ Handles writing output and errors ○ Manages multiple invocations ● Makes it a lot easier to write hot functions
  • 61. FDKs ● Ruby ( https://github.com/fnproject/fdk-ruby ) ● Others ○ Python ○ Go ○ Java ○ Node ○ Rust ○ ...more on the way...
  • 62. Without an FDK ● Dockerfile ● func.yaml ● func.* (e.g. func.sh) ● DIY
  • 63.
  • 65. Flow ● Promises based Orchestration ○ No new “special” language ○ Composable ○ Flexible ○ Supports “Saga Pattern” ● A Flow is... ○ ...written in Code ○ ...written as Function ○ ...deployed as a function (within an application)
  • 66. Flow ● Language Support: ○ Java ○ Python ○ Node ● In the works: ○ Go ● To - do: ○ Ruby
  • 67. As You Like It bitbucket.org/ewan_slater/comedy/src/master/
  • 68. Summary ● FaaS ⇒ Greater developer productivity ● Fn Project ⇒ FaaS Framework ○ Open Source ○ Portable ○ Language Agnostic ○ Multiple FDKs ● Feedback and contributions welcome!
  • 69. Links & Contact ● Fn Project ( fnproject.io ) ○ github.com/fnproject ○ Slack ● Twitter ○ Fn Project: @fnproj ○ Me: @ewanslater
  • 70. Proceed, proceed: we will begin these rites, As we do trust they'll end, in true delights. (all exit to the pub)