liveBook · Manning

Event source

As explained in Platform Engineering on Kubernetes

An event source is a component that produces events and exposes them for delivery to event consumers.

An event source is a component that produces events and exposes them for delivery to consumers. In a metrics pipeline, sources provide CloudEvents that can be stored, transformed into CDEvents, and processed into measurements. section 9.2.2 section 9.2

Common event sources include:

  • Knative Eventing sources such as APIServerSource, PingSource, GitHubSource, GitLabSource, RabbitMQSource, and KafkaSource. section 9.2.4
  • Tool-specific producers from Tekton, Knative Eventing, and Argo Events, including sources for pipelines, tasks, Git providers, Slack, and Stripe. section 9.2
  • Custom sources for systems that already produce events but do not emit CloudEvents. section 9.2.4

Sources should be normalized to CloudEvents before entering the collection pipeline. An event endpoint stores incoming events, while later routing, transformation, and calculation stages decide which events to process. Persistent storage separates collection from downstream processing and supports extensible mappings to CDEvents. section 9.2.2 section 9.2.7

Kubernetes deployment events

An ApiServerSource watches Kubernetes Event resources and sends matching CloudEvents to a service such as cloudevents-raw-service. Those events can be stored, filtered, transformed into CDEvents, and used to calculate deployment frequency. section 9.2.4 section 9.2.7

Listing 9.1 Knative Source APIServerSource definition
apiVersion: sources.knative.dev/v1
kind: ApiServerSource                         #1
metadata:
 name: main-api-server-source                 #2
spec:
 serviceAccountName: api-server-source-sa     #3
 mode: Resource
 resources:
   - apiVersion: v1
     kind: Event                              #4
 sink:                                        #5
   ref:
     apiVersion: v1
     kind: Service
     name: cloudevents-raw-service
     namespace: dora-cloudevents

Inspect the declarative ApiServerSource definition, including its service account, watched Kubernetes resource, and event sink. section 9.2.4

How Platform Engineering on Kubernetes covers it

How deep it goes
Explains source types, CloudEvents normalization, declarative configuration, routing, and persistence, but defers custom-source implementation details.
Examples
Demonstrates Knative API Server, GitHub, GitLab, Kafka, RabbitMQ, Tekton, Argo Events, and Kubernetes deployment-event sources.
What it assumes
Assumes source data can be transformed into CloudEvents before collection and processed through the pipeline.
What you can do after
Apply it via Knative Eventing by configuring a source, sending CloudEvents to a sink, and feeding downstream metric calculations.
How it connects
Connects event sources with CloudEvents, CDEvents, Knative Eventing, event stores, routing, and DORA metrics.

Also explained in

Compare how 2 books explain event source →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Platform Engineering on Kubernetes. The section links point to the parts of the book it draws on.