KUBERNETES
KUBERNETES
SERVERLESS
SERVERLESS
FRAMEWORKS
FRAMEWORKS
Adrian Kosmaczewski
Slide 2
Slide 2 text
"Serverless"
"FaaS"
Slide 3
Slide 3 text
Martin Fowler
— martinfowler.com/articles/serverless.html
FaaS is about running backend code
without managing your own server
systems or your own long-lived
server applications.
Slide 4
Slide 4 text
No content
Slide 5
Slide 5 text
HOW DOES IT WORK?
HOW DOES IT WORK?
Slide 6
Slide 6 text
Bernd Erk
@gethash
How #serverless actually works. #devopsdays
236 1:35 PM - Oct 29, 2019
94 people are talking about this
AGENDA
AGENDA
1. Project details
2. Demos (three, on minikube)
3. Available triggers
4. Supported programming languages
Slide 9
Slide 9 text
1. OPENFAAS
1. OPENFAAS
Slide 10
Slide 10 text
OPENFAAS
OPENFAAS
Written in Go
~16000 stars
~120 contributors
Latest version 0.18.2 (October 15th, 2019)
Independent project through donations
(Patreon, OpenCollective, PayPal)
www.openfaas.com
@openfaas
github.com/openfaas/faas
Slide 11
Slide 11 text
OPENFAAS CHARACTERISTICS
OPENFAAS CHARACTERISTICS
Based on Docker
Functions packaged in containers
Requires Docker in the local machine
Manages Docker les on behalf of developer
Template "store"
CLI: faas-cli
API with Swagger
Serverless Framework plugin
OPENFAAS LANGUAGES
OPENFAAS LANGUAGES
C#, F== (.NET Core)
Go
JavaScript (Node.js)
Java (JVM) 8 & 12
PHP 7
Python / Python 3
Ruby
github.com/openfaas/templates
Slide 16
Slide 16 text
2. FN PROJECT
2. FN PROJECT
Slide 17
Slide 17 text
FN PROJECT
FN PROJECT
Written in Go
~4300 stars
~80 contributors
Latest version 0.3.739 (October 18th, 2019)
Funded by Oracle (Oracle Functions is a fork)
fnproject.io
@fnproject
github.com/fnproject/fn
FN PROJECT LANGUAGES
FN PROJECT LANGUAGES
Go
JavaScript (Node.js)
Java (JVM)
Python
Ruby
C== (community supported)
"Supports all languages"
Slide 21
Slide 21 text
3. FISSION
3. FISSION
Slide 22
Slide 22 text
FISSION
FISSION
Written in Go
~4700 stars
~90 contributors
Latest version 1.6.0 (October 10th, 2019)
Maintained by
ssion.io
@ ssionio
github.com/ ssion/ ssion
Platform9
Slide 23
Slide 23 text
FISSION CHARACTERISTICS
FISSION CHARACTERISTICS
Functions are injected into "Environments"
Pool of containers with language
runtimes
Functions loaded and launched on
demand
CLI: fission
Serverless Framework plugin
Slide 24
Slide 24 text
asciinema
$ cat samples/fission.js
module.exports = async function(context) {
return {
status: 200,
body: "Hello VSHN from Fission!\n"
};
}
asciinema
$ fission env create --name nodejs --image fission/node-env
environment 'nodejs' created
asciinema
$ fission function create --name vshn --env nodejs --code samples/fission.js
Package 'fission-js-i0nl' created
function 'vshn' created
asciinema
$ fission function test
00:00
Slide 25
Slide 25 text
FISSION TRIGGERS
FISSION TRIGGERS
HTTP
Time
Message Queue
Kubernetes Watch
Slide 26
Slide 26 text
FISSION LANGUAGES
FISSION LANGUAGES
Go
Python
JavaScript (Node.js)
Java (JVM)
Slide 27
Slide 27 text
4. OPENWHISK
4. OPENWHISK
Slide 28
Slide 28 text
OPENWHISK
OPENWHISK
Written in Scala
~4300 stars
~160 contributors
Latest version 0.9.0 (October 31st, 2018)
Started by IBM, maintained by the Apache
Foundation
openwhisk.apache.org
@openwhisk
github.com/apache/openwhisk
Slide 29
Slide 29 text
OPENWHISK
OPENWHISK
CHARACTERISTICS
CHARACTERISTICS
Very "corporate" in design and functionality
Secure by default
Forked by Adobe and other big corporations
CLI: wsk
Serverless Framework plugin
Slide 30
Slide 30 text
OPENWHISK TRIGGERS
OPENWHISK TRIGGERS
Message Queues
Databases
Document Stores
Website or Web Apps
Service APIs
IoT Frameworks…
Couchbase
Slide 31
Slide 31 text
OPENWHISK LANGUAGES
OPENWHISK LANGUAGES
C#, F== (.NET Core)
JavaScript (Node.js)
Swift
Java, Scala (JVM)
Go
Python, PHP, Ruby
Ballerina
Through Docker Actions: Rust, Haskell…
Slide 32
Slide 32 text
5. KUBELESS
5. KUBELESS
Slide 33
Slide 33 text
KUBELESS
KUBELESS
Written in Go
~5100 stars
~80 contributors
Latest version 1.0.5 (October 16th, 2019)
Maintained by
kubeless.io
github.com/kubeless/kubeless
Bitnami
Slide 34
Slide 34 text
KUBELESS CHARACTERISTICS
KUBELESS CHARACTERISTICS
Simplest to install and use
Aims to similarity with AWS Lambda
CLI compliant with AWS Lambda CLI
Prometheus monitoring of functions calls and
latency
CLI: kubeless
Serverless Framework plugin
Slide 35
Slide 35 text
asciinema
$ cat kubeless.py
def hello(event, context):
print event
return "Hello CNC from " + event['data']
asciinema
$ kubeless function deploy hello --runtime python2.7 --from-file kubeless.py --handler
kubeless.hello
INFO[0000] Deploying function...
INFO[0000] Function hello submitted for deployment
INFO[0000] Check the deployment status executing 'kubeless function ls hello'
asciinema
$ kubectl get functions
NAME AGE
hello 6s
asciinema
$
00:00
KUBELESS LANGUAGES
KUBELESS LANGUAGES
Go
Python
JavaScript (Node.js)
Java (JVM)
Ruby
C#, F== (.NET Core)
Ballerina
Custom runtimes possible
Slide 39
Slide 39 text
6. TRIGGERMESH
6. TRIGGERMESH
Slide 40
Slide 40 text
TRIGGERMESH
TRIGGERMESH
Founded ex-Kubeless engineers
Based upon Kubernetes & Knative
triggermesh.com
@triggermesh
Slide 41
Slide 41 text
TRIGGERMESH
TRIGGERMESH
CHARACTERISTICS
CHARACTERISTICS
Based on Kubernetes & Knative
CLI: tm
Not yet open source
"Early Access Program"
TriggerMesh Operator for OpenShift 4.0
CI/CD of functions
Slide 42
Slide 42 text
No content
Slide 43
Slide 43 text
TRIGGERMESH TRIGGERS
TRIGGERMESH TRIGGERS
Cross-cloud triggers from AWS & Azure to
functions on Knative
Code Commit
Cognito
DynamoDB
Kinesis
S3
SNS
SQS…
Slide 44
Slide 44 text
TRIGGERMESH LANGUAGES
TRIGGERMESH LANGUAGES
Go
JavaScript (Node.js)
Python
Ruby