From 6cdae1ae3a333fab04f4675f0a53c2167d2bee6e Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:07:42 -0800 Subject: [PATCH 1/7] Update README with some more project explanation --- README.md | 65 +++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 44 insertions(+), 21 deletions(-) diff --git a/README.md b/README.md index 30bc4902..09d4ce9c 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,46 @@ -Fission -======= +Fission: Serverless Functions for Kubernetes +============================================ Fission is a fast serverless framework for Kubernetes with a focus on -developer productivity and high performance. +developer productivity and high performance. See http://fission.io +for more. -It's customizable (with sensible defaults), extensible to any -language, and interoperates well with other infrastructure. +Fission operates on just code: you don't deal with Docker or +Kubernetes, they're abstracted away. -See http://fission.io for more. +We're built on Kubernetes because we think any non-trivial app will +use a combination of serverless functions and more conventional +microservices, and Kubernetes is a great framework to bring these +together seamlessly. + +Fission maintains a pool of "warm" containers that each contain a +small dynamic loader. When a function is first called, +i.e. "cold-started", a running container is chosen and the function is +loaded. This pool is what makes Fission fast: cold-start latencies +are typically about 100msec. + +Fission is extensible to any language. It currently supports NodeJS +and Python, with more languages coming soon. + +Fission Concepts +================ + +A _function_ is a piece of code with an entry point. + +An _environment_ is a container with a webserver and dynamic loader +for functions. Today, Fission comes with NodeJS and Python +environments and you can also add your own. So for example if you +want to add some binaries to your Python image and call them from your +code, you can edit the Python environment's Dockerfile, rebuild it, +and add it to Fission. + +A _trigger_ is something that maps an event to a function; Fission +supports HTTP triggers today, with upcoming support for other types of +event triggers. -Running Fission -=============== +Running Fission on your Cluster +=============================== ### Setup Kubernetes @@ -70,6 +99,10 @@ for the examples below to work.) Compiling Fission ================= +[You only need to do this if you're making Fission changes; if you're +just deploying Fission, use fission.yaml which points to prebuilt +images.] + You'll need go installed, along with the glide dependecy management tool. You'll also need docker for building images. @@ -108,17 +141,7 @@ If you're changing the CLI: Status ====== -Fission is in early alpha. Don't use it in production just yet, but -play with it and give us feedback! - - - - -Performance -=========== - -The alpha release has focussed on cold-start latency performance. For -requests that don't have a running instance, i.e. a "cold start", -fission has a latency overhead of less than 100 msec for the NodeJS -environment. +Fission is in early alpha. Don't use it in production just yet. +We're looking for developer feedback -- tell us which languages you +care about, what use cases you might use it for, and so on. From c733864df57c8174964477859274bc3cae542327 Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:11:56 -0800 Subject: [PATCH 2/7] readme updates --- README.md | 36 ++++++++++++++++++++++-------------- 1 file changed, 22 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index 09d4ce9c..a821da08 100644 --- a/README.md +++ b/README.md @@ -2,16 +2,16 @@ Fission: Serverless Functions for Kubernetes ============================================ Fission is a fast serverless framework for Kubernetes with a focus on -developer productivity and high performance. See http://fission.io -for more. +developer productivity and high performance. -Fission operates on just code: you don't deal with Docker or -Kubernetes, they're abstracted away. +Fission operates on _just code_: Docker and Kubernetes are abstracted +away. -We're built on Kubernetes because we think any non-trivial app will -use a combination of serverless functions and more conventional -microservices, and Kubernetes is a great framework to bring these -together seamlessly. +Fission is extensible to any language. It currently supports NodeJS +and Python, with more languages coming soon. + +100msec cold start +------------------ Fission maintains a pool of "warm" containers that each contain a small dynamic loader. When a function is first called, @@ -19,8 +19,16 @@ i.e. "cold-started", a running container is chosen and the function is loaded. This pool is what makes Fission fast: cold-start latencies are typically about 100msec. -Fission is extensible to any language. It currently supports NodeJS -and Python, with more languages coming soon. + +Kubernetes is the right place for Serverless +-------------------------------------------- + +We're built on Kubernetes because we think any non-trivial app will +use a combination of serverless functions and more conventional +microservices, and Kubernetes is a great framework to bring these +together seamlessly. + + Fission Concepts ================ @@ -29,10 +37,10 @@ A _function_ is a piece of code with an entry point. An _environment_ is a container with a webserver and dynamic loader for functions. Today, Fission comes with NodeJS and Python -environments and you can also add your own. So for example if you -want to add some binaries to your Python image and call them from your -code, you can edit the Python environment's Dockerfile, rebuild it, -and add it to Fission. +environments. You can also add your own: for example, if you want to +add a binary to your Python image, you can edit the Python +environment's Dockerfile, rebuild it, and add your new environment to +Fission. A _trigger_ is something that maps an event to a function; Fission supports HTTP triggers today, with upcoming support for other types of From 3b5139dca300140bec1cdcc22973672576e0be1f Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:22:10 -0800 Subject: [PATCH 3/7] readme updates --- README.md | 60 ++++++++++++++++++++++++++++++++++++------------------- 1 file changed, 40 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index a821da08..6b6eb6dc 100644 --- a/README.md +++ b/README.md @@ -5,13 +5,15 @@ Fission is a fast serverless framework for Kubernetes with a focus on developer productivity and high performance. Fission operates on _just code_: Docker and Kubernetes are abstracted -away. +away under normal operation, though you can use both to extend Fission +if you want to. -Fission is extensible to any language. It currently supports NodeJS -and Python, with more languages coming soon. +Fission is extensible to any language; the core is written in Go, +language-specific parts are isolated in something called +_environments_ (more below). Fission currently supports NodeJS and +Python, with more languages coming soon. -100msec cold start ------------------- +### Performance: 100msec cold start Fission maintains a pool of "warm" containers that each contain a small dynamic loader. When a function is first called, @@ -19,32 +21,50 @@ i.e. "cold-started", a running container is chosen and the function is loaded. This pool is what makes Fission fast: cold-start latencies are typically about 100msec. - -Kubernetes is the right place for Serverless --------------------------------------------- +### Kubernetes is the right place for Serverless We're built on Kubernetes because we think any non-trivial app will use a combination of serverless functions and more conventional microservices, and Kubernetes is a great framework to bring these together seamlessly. - - Fission Concepts -================ +---------------- -A _function_ is a piece of code with an entry point. +A _function_ is a piece of code that follows the fission function +interface. -An _environment_ is a container with a webserver and dynamic loader -for functions. Today, Fission comes with NodeJS and Python -environments. You can also add your own: for example, if you want to -add a binary to your Python image, you can edit the Python -environment's Dockerfile, rebuild it, and add your new environment to -Fission. +An _environment_ contains the language- and runtime-specific parts of +running a function. Fission comes with NodeJS and Python +environments; you can also extend environments or create entirely new +ones if you want. (An environment is essentially just a container +with a webserver and dynamic loader.) A _trigger_ is something that maps an event to a function; Fission -supports HTTP triggers today, with upcoming support for other types of -event triggers. +supports HTTP routes as triggers today, with upcoming support for +other types of event triggers, such as timers and Kubernetes events. + +Fission 101 +----------- + +```bash + + # Add the stock NodeJS env to your Fission deployment + $ fission env create --name nodejs --image fission/node-env + + # A one-liner that prints "hello world" + $ echo 'module.exports = function(context, callback) { callback(200, "Hello, world!\n"); }' > hello.js + + # Upload your function code to fission + $ fission function create --name hello --env nodejs --code hello.js + + # Map GET /hello to your new function + $ fission route create --method GET --url /hello --function hello + + # Run the function. This takes about 100msec the first time. + $ curl http://$FISSION_ROUTER/hello + Hello, world! +``` Running Fission on your Cluster From 05bc663b3fdcc2a55e95fab2ac965d4f30b05a1b Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:28:41 -0800 Subject: [PATCH 4/7] readme updates --- README.md | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 6b6eb6dc..eedca644 100644 --- a/README.md +++ b/README.md @@ -44,15 +44,15 @@ A _trigger_ is something that maps an event to a function; Fission supports HTTP routes as triggers today, with upcoming support for other types of event triggers, such as timers and Kubernetes events. -Fission 101 ------------ +Usage +----- ```bash # Add the stock NodeJS env to your Fission deployment $ fission env create --name nodejs --image fission/node-env - # A one-liner that prints "hello world" + # A javascript one-liner that prints "hello world" $ echo 'module.exports = function(context, callback) { callback(200, "Hello, world!\n"); }' > hello.js # Upload your function code to fission @@ -169,7 +169,8 @@ If you're changing the CLI: Status ====== -Fission is in early alpha. Don't use it in production just yet. -We're looking for developer feedback -- tell us which languages you -care about, what use cases you might use it for, and so on. +Fission is in early alpha. Don't use it in production just yet! +Right now, we're looking for developer feedback -- tell us which +languages you care about, what use cases you might use it for, and so +on. From c3187a2d2364af73cd8e0ef7e68068247dcb2d97 Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:31:24 -0800 Subject: [PATCH 5/7] web and twitter links --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index eedca644..ff02efee 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,6 @@ Fission: Serverless Functions for Kubernetes ============================================ +[fission.io](http://fission.io) [@fissionio](http://twitter.com/fissionio) Fission is a fast serverless framework for Kubernetes with a focus on developer productivity and high performance. @@ -8,7 +9,7 @@ Fission operates on _just code_: Docker and Kubernetes are abstracted away under normal operation, though you can use both to extend Fission if you want to. -Fission is extensible to any language; the core is written in Go, +Fission is extensible to any language; the core is written in Go, and language-specific parts are isolated in something called _environments_ (more below). Fission currently supports NodeJS and Python, with more languages coming soon. @@ -28,6 +29,7 @@ use a combination of serverless functions and more conventional microservices, and Kubernetes is a great framework to bring these together seamlessly. + Fission Concepts ---------------- @@ -174,3 +176,4 @@ Fission is in early alpha. Don't use it in production just yet! Right now, we're looking for developer feedback -- tell us which languages you care about, what use cases you might use it for, and so on. + From c213f18bbb05dda05fcb98e099eb1008f5fc1d2c Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:33:48 -0800 Subject: [PATCH 6/7] k8s benefits --- README.md | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index ff02efee..97dd6ae0 100644 --- a/README.md +++ b/README.md @@ -5,9 +5,9 @@ Fission: Serverless Functions for Kubernetes Fission is a fast serverless framework for Kubernetes with a focus on developer productivity and high performance. -Fission operates on _just code_: Docker and Kubernetes are abstracted -away under normal operation, though you can use both to extend Fission -if you want to. +Fission operates on _just the code_: Docker and Kubernetes are +abstracted away under normal operation, though you can use both to +extend Fission if you want to. Fission is extensible to any language; the core is written in Go, and language-specific parts are isolated in something called @@ -29,6 +29,10 @@ use a combination of serverless functions and more conventional microservices, and Kubernetes is a great framework to bring these together seamlessly. +Building on Kubernetes also means that anything you do for operations +on your Kubernetes cluster -- such as monitoring or log aggregation -- +also helps with ops on your Fission deployment. + Fission Concepts ---------------- From a2df49c04fac7149a81c4345f81a7e4a0f5eb46d Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 17 Nov 2016 16:35:56 -0800 Subject: [PATCH 7/7] typo --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 97dd6ae0..b86821b4 100644 --- a/README.md +++ b/README.md @@ -30,8 +30,8 @@ microservices, and Kubernetes is a great framework to bring these together seamlessly. Building on Kubernetes also means that anything you do for operations -on your Kubernetes cluster -- such as monitoring or log aggregation -- -also helps with ops on your Fission deployment. +on your Kubernetes cluster — such as monitoring or log +aggregation — also helps with ops on your Fission deployment. Fission Concepts