Documentation ¶
Index ¶
Constants ¶
View Source
const ControllerName = "seed-lease"
ControllerName is the name of this controller.
Variables ¶
View Source
var CheckSeedConnection = func(ctx context.Context, client rest.Interface) error { result := client.Get().AbsPath("/healthz").Do(ctx) if result.Error() != nil { return fmt.Errorf("failed to execute call to Kubernetes API Server: %v", result.Error()) } var statusCode int result.StatusCode(&statusCode) if statusCode != http.StatusOK { return fmt.Errorf("API Server returned unexpected status code: %d", statusCode) } return nil }
CheckSeedConnection is a function which checks the connection to the seed. Exposed for testing.
Functions ¶
This section is empty.
Types ¶
type Reconciler ¶
type Reconciler struct { GardenClient client.Client SeedRESTClient rest.Interface Config config.SeedControllerConfiguration Clock clock.Clock HealthManager healthz.Manager LeaseNamespace string SeedName string }
Reconciler reconciles Seed resources and updates the heartbeat Lease object in the garden cluster when the connection to the seed cluster succeeds.
func (*Reconciler) AddToManager ¶
AddToManager adds Reconciler to the given manager.
Click to show internal directories.
Click to hide internal directories.