util

package
v0.0.0-...-9de48e1 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsTransientClientErr

func IsTransientClientErr(err error) bool

IsTransientClientErr checks if the error is a transient error This suggests that a retry (without any change) might be successful

func StartLease

func StartLease()

Types

type ReloadableHubClient

type ReloadableHubClient struct {
	client.Client
	// contains filtered or unexported fields
}

ReloadableHubClient is a wrapper around the hub client that allows reloading the client. This is useful when the kubeconfig file is updated.

func NewReloadableHubClient

func NewReloadableHubClient(filePath string, clientScheme *runtime.Scheme) (*ReloadableHubClient, error)

NewReloadableHubClient creates a new hub client with a reload function.

func NewReloadableHubClientWithReloadFunc

func NewReloadableHubClientWithReloadFunc(reload func() (client.Client, error)) (*ReloadableHubClient, error)

NewReloadableHubClientWithReloadFunc creates a new hub client with a reload function. The reload function is called when the Reload method is called. This can be handy for testing purposes.

func (*ReloadableHubClient) Reload

Reload reloads the hub client and returns a new instance of HubClientWithReload. HubClientWithReload is immutable.

Jump to

Keyboard shortcuts

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