SlideShare a Scribd company logo
The Fn Project
Gabriele Provinciali
Luca Postacchini
Open Source Serverless Computing
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)
● Faas is the compute component in a serverless architecture
Functions-as-a-Service
● Functions are small bits of code that do one thing well and are
easy to understand and maintain
● As a service means no complicated plumbing, the system
takes care of provisioning, scaling, patching, maintaining, etc.
Each function scales independently.
In mathematics, a function is a relation between a set
of inputs and a set of permissible outputs with the
property that each input is related to exactly one output.
Function (mathematics) - Wikipedia
https://en.wikipedia.org/wiki/Function_(mathematics)
Containers vs Functions
Function is a container with a
set of known traits:
● Short running
● Ephemeral
● Stateless
● Invoked
● Single Purpose
● Self-contained
What about Microservices?
Introducing the Fn Project
● Launched in October focused on open source (apache 2),
multi-cloud, serverless services, starting with FaaS
● Iron.io team joined Oracle, now a 20-person “serverless” org
● Maniacal focus on the developer experience
● Independently governed at github.com/fnproject (currently)
● Members on the CNCF serverless working group
● We are building our community and partnerships
For Developers
An Fn Function
● Small chunk of code wrapped into a container image
● Gets input via STDIN and environment
● Produces output to STDOUT
● Logs to STDERR
The Fn server handles everything else, like the API gateway,
piping things around, storing logs, etc.
Fn CLI
● fn init --runtime go
● fn run
● fn test
● fn deploy --app myapp
● fn call myapp myfunc
→ http://localhost:8080/r/myapp/myfunc
Function Development Kits (FDKs)
● Used to help with parsing input and writing output
● Familiar syntax for Lambda developers
● Simply write a `handler` function that adheres to the FDK’s
interface and it will parse STDIN and provide the input data to
your function and deal with writing the proper output format.
● Makes it a lot easier to write hot functions
Debugging
● fn calls list myapp
● fn calls get myapp <call-id>
● fn logs get myapp <call-id>
● Metrics created using OpenTracing w/ initial collectors and
extensions for Prometheus, ZipKin, and soon Jaeger
Fn UI
Under the Hood
Architecture
Detailed Arch
Fn Server
● Handles CRUD operations for setting up routes and functions
● Executes sync functions, returning responses to clients
immediately
● Queues async function calls
● Executes async functions when capacity is available
● Written in Go, easy to extend via plugin module system
Fn LB
● Simple, fast load balancer that routes functions to certain
nodes consistently for hot function efficiency
● Scales each function independently based on traffic to any
particular function
● Can be used to scale Fn servers and infrastructure as well as it
has a view of global state of all fn servers
Fn LB Details
Supporting Services
● DB, MQ, blob store are all pluggable modules that are thin
wrappers around their respective drivers.
○ DB: MySQL, sqlite3, Postgres
○ Queue: Redis, Kafka
○ Registry: Any Docker v2-compliant, even private
● Metrics/Monitoring
○ OpenTracing API for metrics
○ Prometheus support, pluggable backends
○ Logging via syslog
Kubernetes
● Fn is scheduler agnostic but lots of optimization/management
work in process to optimize on Kubernetes
● Helm chart available at https://github.com/fnproject/fn-helm
● Thinking about deeper Kubernetes integrations including
CRD’s to model functions
Helm Chart for K8S
IaaS
Environment
K8S
Cluster
Fn Instance
within K8S
terraform init
terraform plan
terraform apply
helm init
helm dep build fn
helm install --name 
myfn fn
export FN_API_URL=<K8S LB url>
fn deploy --name myapp /comuni
fn apps list
fn routes list myapp
Fn Demo
More Advanced Fn
Fn Flow
● Build long-running, reliable, scalable functions with rich sets of
language-specific primitives including fork-join, chaining, delays
and error handling
● Supports complex parallel processes that are readable and
testable (including unit tests) with standard programming tools
● Java support using CompletableFuture API from Java 8 with
JS, Python, Go language support on the way!
Plate Detect
Function
Draw
Function
Slack
Function
Twitter
Function
Scraper
Scraper
Plate Detect
Function
Draw
Function
Slack
Function
Twitter
Function
FlowFuture.invoke()
thenCompose()
thenCompose()
allOf()
whenComplete()
Scraper
Plate Detect
Function
Draw
Function
Slack
Function
Twitter
Function
FlowFuture.invoke()
thenCompose()
thenCompose()
allOf()
whenComplete()
Flow Function
Open Source Serverless: a practical view. - Gabriele Provinciali Luca Postacchini - Codemotion Rome 2018
Flow Demo
Thank you!
1. Star the project: github.com/fnproject/fn
2. Join the conversation: slack.fnproject.io
3. Learn more: fnproject.io
Get Involved
Appendix
The Fn Project
FDK’sFn Server Fn Flow

More Related Content

PDF
Flink Forward Berlin 2017: Patrick Lucas - Flink in Containerland
PDF
Flink Forward Berlin 2017: Dominik Bruhn - Deploying Flink Jobs as Docker Con...
PDF
[Draft] Fast Prototyping with DPDK and eBPF in Containernet
PDF
Flink Connector Development Tips & Tricks
ODP
Oslo Vancouver Project Update
PDF
Time to-live: How to Perform Automatic State Cleanup in Apache Flink - Andrey...
PDF
OSDC 2018 - Distributed monitoring
PDF
Flink Forward San Francisco 2019: Managing Flink on Kubernetes - FlinkK8sOper...
Flink Forward Berlin 2017: Patrick Lucas - Flink in Containerland
Flink Forward Berlin 2017: Dominik Bruhn - Deploying Flink Jobs as Docker Con...
[Draft] Fast Prototyping with DPDK and eBPF in Containernet
Flink Connector Development Tips & Tricks
Oslo Vancouver Project Update
Time to-live: How to Perform Automatic State Cleanup in Apache Flink - Andrey...
OSDC 2018 - Distributed monitoring
Flink Forward San Francisco 2019: Managing Flink on Kubernetes - FlinkK8sOper...

What's hot (20)

PDF
Apache Software Foundation: How To Contribute, with Apache Flink as Example (...
PDF
An Introduction to Core 4
PDF
Flink Forward San Francisco 2019: Building production Flink jobs with Airstre...
PDF
Flink Forward Berlin 2017: Zohar Mizrahi - Python Streaming API
PDF
OSMC 2021 | Robotmk: You don’t run IT – you deliver services!
PDF
Fluent-bit
PPTX
Architecture Sustaining LINE Sticker services
PPTX
Apache Kafka : Monitoring vs Alerting
PDF
20171027 モニタリング勉強会
PDF
Streaming your Lyft Ride Prices - Flink Forward SF 2019
PDF
Python Streaming Pipelines on Flink - Beam Meetup at Lyft 2019
PDF
Future of Apache Flink Deployments: Containers, Kubernetes and More - Flink F...
PDF
Flink Forward San Francisco 2019: The Trade Desk's Year in Flink - Jonathan ...
PDF
Flink Forward Berlin 2017: Maciek Próchniak - TouK Nussknacker - creating Fli...
PDF
Flink Forward San Francisco 2019: Scaling a real-time streaming warehouse wit...
PDF
Flink Forward San Francisco 2019: Apache Beam portability in the times of rea...
PPTX
Python Streaming Pipelines with Beam on Flink
PDF
Kong in 1.x Territory
PPTX
Flink Forward Berlin 2017: Till Rohrmann - From Apache Flink 1.3 to 1.4
PDF
Saltstack for Ansible users
Apache Software Foundation: How To Contribute, with Apache Flink as Example (...
An Introduction to Core 4
Flink Forward San Francisco 2019: Building production Flink jobs with Airstre...
Flink Forward Berlin 2017: Zohar Mizrahi - Python Streaming API
OSMC 2021 | Robotmk: You don’t run IT – you deliver services!
Fluent-bit
Architecture Sustaining LINE Sticker services
Apache Kafka : Monitoring vs Alerting
20171027 モニタリング勉強会
Streaming your Lyft Ride Prices - Flink Forward SF 2019
Python Streaming Pipelines on Flink - Beam Meetup at Lyft 2019
Future of Apache Flink Deployments: Containers, Kubernetes and More - Flink F...
Flink Forward San Francisco 2019: The Trade Desk's Year in Flink - Jonathan ...
Flink Forward Berlin 2017: Maciek Próchniak - TouK Nussknacker - creating Fli...
Flink Forward San Francisco 2019: Scaling a real-time streaming warehouse wit...
Flink Forward San Francisco 2019: Apache Beam portability in the times of rea...
Python Streaming Pipelines with Beam on Flink
Kong in 1.x Territory
Flink Forward Berlin 2017: Till Rohrmann - From Apache Flink 1.3 to 1.4
Saltstack for Ansible users
Ad

Similar to Open Source Serverless: a practical view. - Gabriele Provinciali Luca Postacchini - Codemotion Rome 2018 (20)

PDF
The Fn Project: A Quick Introduction (December 2017)
PDF
The Fn Project by Jesse Butler
PDF
Serverless Boston @ Oracle Meetup
PDF
Free the Functions with Fn project!
PPTX
The FN Project by Maximilian Jerg
PPTX
Democratizing Serverless
PPTX
Serverless design with Fn project
PDF
"Wie passen Serverless & Autonomous zusammen?"
PPTX
Democratizing Serverless: the New Open Source, Cloud Agnostic Functions Platf...
PDF
Monkey Server
PDF
CNCF Singapore - Introduction to Envoy
PDF
Getting Started: Intro to Telegraf - July 2021
PDF
GCP overview
PDF
Tim Hall and Ryan Betts [InfluxData] | InfluxDB Roadmap and Engineering Updat...
PDF
Go at uber
PDF
LCA13: LAVA and CI Component Review
PPTX
Delivering Cloud Native Batch Solutions - Dodd Pfeffer
PDF
Integration Microservices
PDF
Devops with Python by Yaniv Cohen DevopShift
PDF
Xpdays: Kubernetes CI-CD Frameworks Case Study
The Fn Project: A Quick Introduction (December 2017)
The Fn Project by Jesse Butler
Serverless Boston @ Oracle Meetup
Free the Functions with Fn project!
The FN Project by Maximilian Jerg
Democratizing Serverless
Serverless design with Fn project
"Wie passen Serverless & Autonomous zusammen?"
Democratizing Serverless: the New Open Source, Cloud Agnostic Functions Platf...
Monkey Server
CNCF Singapore - Introduction to Envoy
Getting Started: Intro to Telegraf - July 2021
GCP overview
Tim Hall and Ryan Betts [InfluxData] | InfluxDB Roadmap and Engineering Updat...
Go at uber
LCA13: LAVA and CI Component Review
Delivering Cloud Native Batch Solutions - Dodd Pfeffer
Integration Microservices
Devops with Python by Yaniv Cohen DevopShift
Xpdays: Kubernetes CI-CD Frameworks Case Study
Ad

More from Codemotion (20)

PDF
Fuzz-testing: A hacker's approach to making your code more secure | Pascal Ze...
PDF
Pompili - From hero to_zero: The FatalNoise neverending story
PPTX
Pastore - Commodore 65 - La storia
PPTX
Pennisi - Essere Richard Altwasser
PPTX
Michel Schudel - Let's build a blockchain... in 40 minutes! - Codemotion Amst...
PPTX
Richard Süselbeck - Building your own ride share app - Codemotion Amsterdam 2019
PPTX
Eward Driehuis - What we learned from 20.000 attacks - Codemotion Amsterdam 2019
PPTX
Francesco Baldassarri - Deliver Data at Scale - Codemotion Amsterdam 2019 -
PDF
Martin Förtsch, Thomas Endres - Stereoscopic Style Transfer AI - Codemotion A...
PDF
Melanie Rieback, Klaus Kursawe - Blockchain Security: Melting the "Silver Bul...
PDF
Angelo van der Sijpt - How well do you know your network stack? - Codemotion ...
PDF
Lars Wolff - Performance Testing for DevOps in the Cloud - Codemotion Amsterd...
PDF
Sascha Wolter - Conversational AI Demystified - Codemotion Amsterdam 2019
PDF
Michele Tonutti - Scaling is caring - Codemotion Amsterdam 2019
PPTX
Pat Hermens - From 100 to 1,000+ deployments a day - Codemotion Amsterdam 2019
PPTX
James Birnie - Using Many Worlds of Compute Power with Quantum - Codemotion A...
PDF
Don Goodman-Wilson - Chinese food, motor scooters, and open source developmen...
PDF
Pieter Omvlee - The story behind Sketch - Codemotion Amsterdam 2019
PDF
Dave Farley - Taking Back “Software Engineering” - Codemotion Amsterdam 2019
PDF
Joshua Hoffman - Should the CTO be Coding? - Codemotion Amsterdam 2019
Fuzz-testing: A hacker's approach to making your code more secure | Pascal Ze...
Pompili - From hero to_zero: The FatalNoise neverending story
Pastore - Commodore 65 - La storia
Pennisi - Essere Richard Altwasser
Michel Schudel - Let's build a blockchain... in 40 minutes! - Codemotion Amst...
Richard Süselbeck - Building your own ride share app - Codemotion Amsterdam 2019
Eward Driehuis - What we learned from 20.000 attacks - Codemotion Amsterdam 2019
Francesco Baldassarri - Deliver Data at Scale - Codemotion Amsterdam 2019 -
Martin Förtsch, Thomas Endres - Stereoscopic Style Transfer AI - Codemotion A...
Melanie Rieback, Klaus Kursawe - Blockchain Security: Melting the "Silver Bul...
Angelo van der Sijpt - How well do you know your network stack? - Codemotion ...
Lars Wolff - Performance Testing for DevOps in the Cloud - Codemotion Amsterd...
Sascha Wolter - Conversational AI Demystified - Codemotion Amsterdam 2019
Michele Tonutti - Scaling is caring - Codemotion Amsterdam 2019
Pat Hermens - From 100 to 1,000+ deployments a day - Codemotion Amsterdam 2019
James Birnie - Using Many Worlds of Compute Power with Quantum - Codemotion A...
Don Goodman-Wilson - Chinese food, motor scooters, and open source developmen...
Pieter Omvlee - The story behind Sketch - Codemotion Amsterdam 2019
Dave Farley - Taking Back “Software Engineering” - Codemotion Amsterdam 2019
Joshua Hoffman - Should the CTO be Coding? - Codemotion Amsterdam 2019

Recently uploaded (20)

PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PPTX
Big Data Technologies - Introduction.pptx
PDF
Encapsulation_ Review paper, used for researhc scholars
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PPT
Teaching material agriculture food technology
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
MIND Revenue Release Quarter 2 2025 Press Release
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Approach and Philosophy of On baking technology
PDF
Review of recent advances in non-invasive hemoglobin estimation
PPTX
Cloud computing and distributed systems.
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
The Rise and Fall of 3GPP – Time for a Sabbatical?
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
Big Data Technologies - Introduction.pptx
Encapsulation_ Review paper, used for researhc scholars
Digital-Transformation-Roadmap-for-Companies.pptx
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Teaching material agriculture food technology
Understanding_Digital_Forensics_Presentation.pptx
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Advanced methodologies resolving dimensionality complications for autism neur...
Dropbox Q2 2025 Financial Results & Investor Presentation
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
20250228 LYD VKU AI Blended-Learning.pptx
MIND Revenue Release Quarter 2 2025 Press Release
The AUB Centre for AI in Media Proposal.docx
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Approach and Philosophy of On baking technology
Review of recent advances in non-invasive hemoglobin estimation
Cloud computing and distributed systems.

Open Source Serverless: a practical view. - Gabriele Provinciali Luca Postacchini - Codemotion Rome 2018

  • 1. The Fn Project Gabriele Provinciali Luca Postacchini Open Source Serverless Computing
  • 2. 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) ● Faas is the compute component in a serverless architecture
  • 3. Functions-as-a-Service ● Functions are small bits of code that do one thing well and are easy to understand and maintain ● As a service means no complicated plumbing, the system takes care of provisioning, scaling, patching, maintaining, etc. Each function scales independently. In mathematics, a function is a relation between a set of inputs and a set of permissible outputs with the property that each input is related to exactly one output. Function (mathematics) - Wikipedia https://en.wikipedia.org/wiki/Function_(mathematics)
  • 4. Containers vs Functions Function is a container with a set of known traits: ● Short running ● Ephemeral ● Stateless ● Invoked ● Single Purpose ● Self-contained
  • 6. Introducing the Fn Project ● Launched in October focused on open source (apache 2), multi-cloud, serverless services, starting with FaaS ● Iron.io team joined Oracle, now a 20-person “serverless” org ● Maniacal focus on the developer experience ● Independently governed at github.com/fnproject (currently) ● Members on the CNCF serverless working group ● We are building our community and partnerships
  • 8. An Fn Function ● Small chunk of code wrapped into a container image ● Gets input via STDIN and environment ● Produces output to STDOUT ● Logs to STDERR The Fn server handles everything else, like the API gateway, piping things around, storing logs, etc.
  • 9. Fn CLI ● fn init --runtime go ● fn run ● fn test ● fn deploy --app myapp ● fn call myapp myfunc → http://localhost:8080/r/myapp/myfunc
  • 10. Function Development Kits (FDKs) ● Used to help with parsing input and writing output ● Familiar syntax for Lambda developers ● Simply write a `handler` function that adheres to the FDK’s interface and it will parse STDIN and provide the input data to your function and deal with writing the proper output format. ● Makes it a lot easier to write hot functions
  • 11. Debugging ● fn calls list myapp ● fn calls get myapp <call-id> ● fn logs get myapp <call-id> ● Metrics created using OpenTracing w/ initial collectors and extensions for Prometheus, ZipKin, and soon Jaeger
  • 12. Fn UI
  • 16. Fn Server ● Handles CRUD operations for setting up routes and functions ● Executes sync functions, returning responses to clients immediately ● Queues async function calls ● Executes async functions when capacity is available ● Written in Go, easy to extend via plugin module system
  • 17. Fn LB ● Simple, fast load balancer that routes functions to certain nodes consistently for hot function efficiency ● Scales each function independently based on traffic to any particular function ● Can be used to scale Fn servers and infrastructure as well as it has a view of global state of all fn servers
  • 19. Supporting Services ● DB, MQ, blob store are all pluggable modules that are thin wrappers around their respective drivers. ○ DB: MySQL, sqlite3, Postgres ○ Queue: Redis, Kafka ○ Registry: Any Docker v2-compliant, even private ● Metrics/Monitoring ○ OpenTracing API for metrics ○ Prometheus support, pluggable backends ○ Logging via syslog
  • 20. Kubernetes ● Fn is scheduler agnostic but lots of optimization/management work in process to optimize on Kubernetes ● Helm chart available at https://github.com/fnproject/fn-helm ● Thinking about deeper Kubernetes integrations including CRD’s to model functions
  • 21. Helm Chart for K8S IaaS Environment K8S Cluster Fn Instance within K8S terraform init terraform plan terraform apply helm init helm dep build fn helm install --name myfn fn export FN_API_URL=<K8S LB url> fn deploy --name myapp /comuni fn apps list fn routes list myapp
  • 24. Fn Flow ● Build long-running, reliable, scalable functions with rich sets of language-specific primitives including fork-join, chaining, delays and error handling ● Supports complex parallel processes that are readable and testable (including unit tests) with standard programming tools ● Java support using CompletableFuture API from Java 8 with JS, Python, Go language support on the way!
  • 30. Thank you! 1. Star the project: github.com/fnproject/fn 2. Join the conversation: slack.fnproject.io 3. Learn more: fnproject.io Get Involved
  • 32. The Fn Project FDK’sFn Server Fn Flow