heartbeat

package
v1.80.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 27, 2023 License: Apache-2.0, BSD-2-Clause, MIT, + 1 more Imports: 13 Imported by: 59

Documentation

Index

Constants

View Source
const ControllerName = "heartbeat"

ControllerName is the name of the controller.

Variables

View Source
var DefaultAddOptions = AddOptions{
	RenewIntervalSeconds: 30,
}

DefaultAddOptions are the default AddOptions for AddToManager.

Functions

func Add

func Add(mgr manager.Manager, args AddArgs) error

Add creates a new heartbeat controller and adds it to the given manager.

func AddToManager

func AddToManager(_ context.Context, mgr manager.Manager) error

AddToManager adds the heartbeat controller with the default Options to the manager.

func NewReconciler

func NewReconciler(mgr manager.Manager, extensionName string, namespace string, renewIntervalSeconds int32, clock clock.Clock) reconcile.Reconciler

NewReconciler creates a new reconciler that will renew the heartbeat lease resource.

Types

type AddArgs

type AddArgs struct {
	// ControllerOptions are the controller.Options.
	ControllerOptions controller.Options
	// ExtensionName is the name of the extension controller.
	ExtensionName string
	// Namespace is the namespace which will be used for the heartbeat lease resource.
	Namespace string
	// RenewIntervalSeconds defines how often the heartbeat lease is renewed.
	RenewIntervalSeconds int32
	// Clock is the clock to use when renewing the heartbeat lease resource.
	Clock clock.Clock
}

AddArgs are arguments for adding a heartbeat controller to a manager.

type AddOptions

type AddOptions struct {
	// ExtensionName is the name of the extension that this heartbeat controller is part of.
	ExtensionName string
	// Namespace is the namespace which will be used for the heartbeat lease resource.
	Namespace string
	// RenewIntervalSeconds defines how often the heartbeat lease is renewed.
	RenewIntervalSeconds int32
}

AddOptions are options to apply when adding the heartbeat controller to the manager.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL