Serverless computing has become a hot topic in developer communities. The use of ephemeral containers eliminates the need for always-on infrastructure.
But the real payoff for serverless is greater code simplicity and developer efficiency. Sounds great! Except the open-source serverless framework space is crowded and complex. Each unique offering approaches functions differently, with varying methods for triggering, scaling, and event formatting. How is that efficient?
One thing that most everybody can agree on is to build on top of Kubernetes. With that as the only common ground though, there is still too much fragmentation for developers to wade through when deciding on the right open source serverless solution.
That's where Knative comes in. An open-source project from Google, Pivotal, and other industry leaders, Knative provides a set of common tooling on top of Kubernetes to help developers build serverless applications.
It extends Kubernetes by combining Istio with Custom Resource Definitions to enable a higher-level of abstraction for developers. This brings support for source-to-container builds, autoscaling, routing, and event sourcing. Join this session with Brian McClain and Bryan Friedman to see a complete working demo of Knative and learn:
● What are the components of Knative and how do they work together
● What are the different ways to deploy serverless applications and functions on Knative
● How and when to use Knative’s build features, such as Buildpacks
● What is Knative’s eventing model and how are event sources used to trigger functions
Presenters:
Bryan Friedman, Director of Product Marketing, Pivotal and Brian McClain, Principal Product Marketing Manager, Pivotal
3. Cover w/ Image
Agenda
■ What is Knative?
■ Knative Components with Examples
■ Project riff
■ Demo Application
■ Q+A
4. Knative: A platform for developers to
build and run serverless applications
atop Kubernetes
5. Eventing
How your code is
triggered by events
● Apps and functions consume
and publish event streams
● Multiple event sources available
● Encourages asynchronous,
loosely coupled architecture
Build
How your code is built and
packaged as a container
● Pluggable model to build
containers from source code
● Build in-cloud or on-cluster
● Push image to registry
● Templates available
(e.g. Buildpacks)
Serving
How your code receives requests
and scales with them
● Request-driven compute runtime
● Scale-to-zero / scale out per load
● Deploy from container registry
● Multiple revisions of same app
● Route traffic across revisions
DETAILS DETAILS DETAILS
Knative Components
6. Serving
Flexible scaling and routing to your application.
● Automatically deploy containers and configure routing
● Automatically scale up and down, including scale-to-zero
● Point-in-time snapshots of deployments allows multiple versions of
applications at once
● Easy rollbacks, blue-green deployments, partial load testing, etc.
19. Build
Build and package code on-cluster.
● Builds are ran completely within Kubernetes
● Code is pulled from git at build time
● Packaged as container images and pushed to a registry of your
choice
● Build Templates are prepackaged descriptions of different ways to
build code
20. Kaniko. Build container images inside of containers
Jib. Build container images optimized for Java applications
Buildpacks. Build container images using Cloud Foundry’s Buildpack
build system
And more! The list of Build Templates is constantly growing
Build Templates
23. Eventing
Robust eventing support that abstracts away the messaging layer.
● Easy for developers to consume events - No messaging-specific
code
● Messaging layer is abstracted from the developer and pluggable
for the operator
● Abstract persistent Channels allows events to be delivered to
multiple functions
● Pluggable, Customizable Event Sources
24. Example Event Sources
Cron Job. Produce events on a specified Cron schedule
GitHub. Events happening in a GitHub repository/organization (commit,
new pull request, etc) trigger your function
Google Cloud Storage. Invokes your function when files are uploaded
or changed in a specified bucket
AWS SQS. Messages on SQS are forwarded to your function
25. Custom Event Sources
Event Sources are pluggable and not tightly bundled to Knative
● Community-developed event sources are installed by applying a
YAML file
● ContainerSource makes it easy to build your own event source
○ Package your event emitter as a container, Knative gives a
URI to POST to
34. Project riff
Makes Knative Better. Tools and extensions to make the Knative
developer experience even better
riff CLI. Make easy to quickly deploy functions to Knative and configure
event channels. Removes the need to manage YAML.
Invokers. Allows developers to focus on their functions, invokers will
handle setting up the webserver and running your code
38. Pivotal's commercially supported, opinionated
packaging of riff + Knative.
Expected to run on PKS or Kubernetes anywhere.
Alpha Release Now Available (by request)
General Availability TBD