SlideShare une entreprise Scribd logo
1  sur  70
Télécharger pour lire hors ligne
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?
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
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
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
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
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
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
FaaS you like it (if Shakespeare had written Functions-as-a-Service)
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)

Contenu connexe

Tendances

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
 

Tendances (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
 

Similaire à 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.
 

Similaire à 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
 

Dernier

Your Vision, Our Expertise: TECUNIQUE's Tailored Software Teams
Your Vision, Our Expertise: TECUNIQUE's Tailored Software TeamsYour Vision, Our Expertise: TECUNIQUE's Tailored Software Teams
Your Vision, Our Expertise: TECUNIQUE's Tailored Software TeamsJaydeep Chhasatia
 
ERP For Electrical and Electronics manufecturing.pptx
ERP For Electrical and Electronics manufecturing.pptxERP For Electrical and Electronics manufecturing.pptx
ERP For Electrical and Electronics manufecturing.pptxAutus Cyber Tech
 
Growing Oxen: channel operators and retries
Growing Oxen: channel operators and retriesGrowing Oxen: channel operators and retries
Growing Oxen: channel operators and retriesSoftwareMill
 
Watermarking in Source Code: Applications and Security Challenges
Watermarking in Source Code: Applications and Security ChallengesWatermarking in Source Code: Applications and Security Challenges
Watermarking in Source Code: Applications and Security ChallengesShyamsundar Das
 
Generative AI for Cybersecurity - EC-Council
Generative AI for Cybersecurity - EC-CouncilGenerative AI for Cybersecurity - EC-Council
Generative AI for Cybersecurity - EC-CouncilVICTOR MAESTRE RAMIREZ
 
Deep Learning for Images with PyTorch - Datacamp
Deep Learning for Images with PyTorch - DatacampDeep Learning for Images with PyTorch - Datacamp
Deep Learning for Images with PyTorch - DatacampVICTOR MAESTRE RAMIREZ
 
Streamlining Your Application Builds with Cloud Native Buildpacks
Streamlining Your Application Builds  with Cloud Native BuildpacksStreamlining Your Application Builds  with Cloud Native Buildpacks
Streamlining Your Application Builds with Cloud Native BuildpacksVish Abrams
 
Cybersecurity Challenges with Generative AI - for Good and Bad
Cybersecurity Challenges with Generative AI - for Good and BadCybersecurity Challenges with Generative AI - for Good and Bad
Cybersecurity Challenges with Generative AI - for Good and BadIvo Andreev
 
Webinar_050417_LeClair12345666777889.ppt
Webinar_050417_LeClair12345666777889.pptWebinar_050417_LeClair12345666777889.ppt
Webinar_050417_LeClair12345666777889.pptkinjal48
 
JS-Experts - Cybersecurity for Generative AI
JS-Experts - Cybersecurity for Generative AIJS-Experts - Cybersecurity for Generative AI
JS-Experts - Cybersecurity for Generative AIIvo Andreev
 
Big Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/ML
Big Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/MLBig Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/ML
Big Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/MLAlluxio, Inc.
 
How Does the Epitome of Spyware Differ from Other Malicious Software?
How Does the Epitome of Spyware Differ from Other Malicious Software?How Does the Epitome of Spyware Differ from Other Malicious Software?
How Does the Epitome of Spyware Differ from Other Malicious Software?AmeliaSmith90
 
eAuditor Audits & Inspections - conduct field inspections
eAuditor Audits & Inspections - conduct field inspectionseAuditor Audits & Inspections - conduct field inspections
eAuditor Audits & Inspections - conduct field inspectionsNirav Modi
 
Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...
Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...
Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...Jaydeep Chhasatia
 
Fields in Java and Kotlin and what to expect.pptx
Fields in Java and Kotlin and what to expect.pptxFields in Java and Kotlin and what to expect.pptx
Fields in Java and Kotlin and what to expect.pptxJoão Esperancinha
 
Enterprise Document Management System - Qualityze Inc
Enterprise Document Management System - Qualityze IncEnterprise Document Management System - Qualityze Inc
Enterprise Document Management System - Qualityze Incrobinwilliams8624
 
Leveraging DxSherpa's Generative AI Services to Unlock Human-Machine Harmony
Leveraging DxSherpa's Generative AI Services to Unlock Human-Machine HarmonyLeveraging DxSherpa's Generative AI Services to Unlock Human-Machine Harmony
Leveraging DxSherpa's Generative AI Services to Unlock Human-Machine Harmonyelliciumsolutionspun
 
online pdf editor software solutions.pdf
online pdf editor software solutions.pdfonline pdf editor software solutions.pdf
online pdf editor software solutions.pdfMeon Technology
 
Top Software Development Trends in 2024
Top Software Development Trends in  2024Top Software Development Trends in  2024
Top Software Development Trends in 2024Mind IT Systems
 
Sales Territory Management: A Definitive Guide to Expand Sales Coverage
Sales Territory Management: A Definitive Guide to Expand Sales CoverageSales Territory Management: A Definitive Guide to Expand Sales Coverage
Sales Territory Management: A Definitive Guide to Expand Sales CoverageDista
 

Dernier (20)

Your Vision, Our Expertise: TECUNIQUE's Tailored Software Teams
Your Vision, Our Expertise: TECUNIQUE's Tailored Software TeamsYour Vision, Our Expertise: TECUNIQUE's Tailored Software Teams
Your Vision, Our Expertise: TECUNIQUE's Tailored Software Teams
 
ERP For Electrical and Electronics manufecturing.pptx
ERP For Electrical and Electronics manufecturing.pptxERP For Electrical and Electronics manufecturing.pptx
ERP For Electrical and Electronics manufecturing.pptx
 
Growing Oxen: channel operators and retries
Growing Oxen: channel operators and retriesGrowing Oxen: channel operators and retries
Growing Oxen: channel operators and retries
 
Watermarking in Source Code: Applications and Security Challenges
Watermarking in Source Code: Applications and Security ChallengesWatermarking in Source Code: Applications and Security Challenges
Watermarking in Source Code: Applications and Security Challenges
 
Generative AI for Cybersecurity - EC-Council
Generative AI for Cybersecurity - EC-CouncilGenerative AI for Cybersecurity - EC-Council
Generative AI for Cybersecurity - EC-Council
 
Deep Learning for Images with PyTorch - Datacamp
Deep Learning for Images with PyTorch - DatacampDeep Learning for Images with PyTorch - Datacamp
Deep Learning for Images with PyTorch - Datacamp
 
Streamlining Your Application Builds with Cloud Native Buildpacks
Streamlining Your Application Builds  with Cloud Native BuildpacksStreamlining Your Application Builds  with Cloud Native Buildpacks
Streamlining Your Application Builds with Cloud Native Buildpacks
 
Cybersecurity Challenges with Generative AI - for Good and Bad
Cybersecurity Challenges with Generative AI - for Good and BadCybersecurity Challenges with Generative AI - for Good and Bad
Cybersecurity Challenges with Generative AI - for Good and Bad
 
Webinar_050417_LeClair12345666777889.ppt
Webinar_050417_LeClair12345666777889.pptWebinar_050417_LeClair12345666777889.ppt
Webinar_050417_LeClair12345666777889.ppt
 
JS-Experts - Cybersecurity for Generative AI
JS-Experts - Cybersecurity for Generative AIJS-Experts - Cybersecurity for Generative AI
JS-Experts - Cybersecurity for Generative AI
 
Big Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/ML
Big Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/MLBig Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/ML
Big Data Bellevue Meetup | Enhancing Python Data Loading in the Cloud for AI/ML
 
How Does the Epitome of Spyware Differ from Other Malicious Software?
How Does the Epitome of Spyware Differ from Other Malicious Software?How Does the Epitome of Spyware Differ from Other Malicious Software?
How Does the Epitome of Spyware Differ from Other Malicious Software?
 
eAuditor Audits & Inspections - conduct field inspections
eAuditor Audits & Inspections - conduct field inspectionseAuditor Audits & Inspections - conduct field inspections
eAuditor Audits & Inspections - conduct field inspections
 
Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...
Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...
Optimizing Business Potential: A Guide to Outsourcing Engineering Services in...
 
Fields in Java and Kotlin and what to expect.pptx
Fields in Java and Kotlin and what to expect.pptxFields in Java and Kotlin and what to expect.pptx
Fields in Java and Kotlin and what to expect.pptx
 
Enterprise Document Management System - Qualityze Inc
Enterprise Document Management System - Qualityze IncEnterprise Document Management System - Qualityze Inc
Enterprise Document Management System - Qualityze Inc
 
Leveraging DxSherpa's Generative AI Services to Unlock Human-Machine Harmony
Leveraging DxSherpa's Generative AI Services to Unlock Human-Machine HarmonyLeveraging DxSherpa's Generative AI Services to Unlock Human-Machine Harmony
Leveraging DxSherpa's Generative AI Services to Unlock Human-Machine Harmony
 
online pdf editor software solutions.pdf
online pdf editor software solutions.pdfonline pdf editor software solutions.pdf
online pdf editor software solutions.pdf
 
Top Software Development Trends in 2024
Top Software Development Trends in  2024Top Software Development Trends in  2024
Top Software Development Trends in 2024
 
Sales Territory Management: A Definitive Guide to Expand Sales Coverage
Sales Territory Management: A Definitive Guide to Expand Sales CoverageSales Territory Management: A Definitive Guide to Expand Sales Coverage
Sales Territory Management: A Definitive Guide to Expand Sales Coverage
 

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?
  • 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
  • 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
  • 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
  • 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)