A Knative event source can be any Kubernetes object that generates or imports cloud events, and relays those events to another endpoint, known as a sink. Sourcing events is critical to developing a distributed system that reacts to events.

You can create and manage Knative event sources by using the Developer perspective in the OpenShift Container Platform web console, the kn CLI, or by applying YAML files.

Currently, OpenShift Serverless supports the following event source types:

API server source

Brings Kubernetes API server events into Knative. The API server source fires a new event each time a Kubernetes resource is created, updated or deleted.

Ping source

Produces events with a fixed payload on a specified cron schedule.

Sink binding

Connects core Kubernetes resource objects, such as Deployment, Job, or StatefulSet objects, with a sink.

Container source

Starts a container image that generates cloud events and sends them to a sink. Container sources can also be used to support your own custom event sources in Knative.

Kafka source

Connects a Kafka cluster to a sink as an event source.