interfaces

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2023 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigAgent

type ConfigAgent interface {
	ResourceUpdated(MetaResource)
	ResourceDeleted(MetaResource)
	Start(chan struct{})
	Stop()
}

ConfigAgent contains the actual implementation of controller logic

type K8sClient

type K8sClient interface {
	PatchDeployment(namespace, name string, data interface{}) error
	PatchStatefulSet(namespace, name string, data interface{}) error
}

K8sClient is a wrapper around update functions for kubernetes to be exchangeable for tests

type MetaConfig

type MetaConfig interface {
	MetaResource
	Checksum() string
}

MetaConfig unifies "config" object types, i.e. ConfigMap and Secret

type MetaDeployment

type MetaDeployment interface {
	MetaResource
	NeedsRestartOnConfigChange() bool
	ReferencedConfigs() []string
	AppliedChecksums() map[string]string
	UpdateConfigChecksums(k8sClient K8sClient, checksums map[string]string, restart bool) error
}

MetaDeployment unifies "deployment" object types, i.e. Deployment and StatefulSet

type MetaResource

type MetaResource interface {
	FullName() string
	Version() string
}

MetaResource is a Kubernetes object that has meta data and is identifiable by some name

Jump to

Keyboard shortcuts

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