-
Notifications
You must be signed in to change notification settings - Fork 229
Open
Labels
area/event-exporterEvent exporter componentEvent exporter componentenhancementgoPull requests that update Go codePull requests that update Go codekind/featureNew feature or requestNew feature or requestpriority/critical-urgentHighest priority issues requiring immediate attentionHighest priority issues requiring immediate attention
Description
Problem
Initial list of Events is expensive for large clusters. Even though the current watcher clears list.Items to avoid local buffering, the apiserver still has to produce and transmit the full list before the watch starts. This delays readiness and increases API load when event volume is high.
Proposed optimization
Use watchlist semantics (SendInitialEvents + watch bookmarks) so the initial state is streamed over watch and ends with a bookmark. This avoids large list bursts and provides a clean sync point for the watcher.
Notes / references
- Watchlist and bookmarks in ListOptions: https://kubernetes.io/docs/reference/using-api/api-concepts/#efficient-detection-of-changes
metav1.ListOptions:AllowWatchBookmarks,SendInitialEvents,ResourceVersionMatch=NotOlderThan- client-go reflector already supports watchlist mode (see
k8s.io/client-go/tools/cache/reflector.go)
Acceptance criteria
- Event watcher uses watchlist for initial sync and handles bookmark completion.
- Startup time and apiserver request volume are reduced vs. full list on large clusters.
- Fallback to list/watch remains in place for clusters that do not support watchlist.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area/event-exporterEvent exporter componentEvent exporter componentenhancementgoPull requests that update Go codePull requests that update Go codekind/featureNew feature or requestNew feature or requestpriority/critical-urgentHighest priority issues requiring immediate attentionHighest priority issues requiring immediate attention