- Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Description
In controller-runtime v0.10, manager.Start(ctx) would propagate that context to all reconcilers. e.g., if you attached a trace context or logger to the context, all reconcilers would be receive that in their context.
https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.11.0/pkg/manager#Manager
https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.11.0/pkg/reconcile#Reconciler
In controller-runtime v0.11, the controller manager creates its own "empty" background context
| r.ctx, r.cancel = context.WithCancel(context.Background()) |
And this is the context passed to the Reconcile(ctx, req) method
Was this an intentional change? are there ways we can add context values in a way that will appear in all reconcilers?
Metadata
Metadata
Assignees
Labels
No labels