controller

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2019 License: Apache-2.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultReapInterval = time.Hour
)

Variables

View Source
var (
	LastSeenResourceVersionGauge = prometheus.NewGauge(
		prometheus.GaugeOpts{
			Subsystem: "controller",
			Namespace: "saiki",
			Name:      "last_seen_resource_version",
			Help:      "The resource version of the last item to be queued.",
		},
	)

	LastProcessedResourceVersionGauge = prometheus.NewGauge(
		prometheus.GaugeOpts{
			Subsystem: "controller",
			Namespace: "saiki",
			Name:      "last_processed_resource_version",
			Help:      "The resource version of the last item to be processed.",
		},
	)

	ProcessingErrorsCounter = prometheus.NewCounter(
		prometheus.CounterOpts{
			Subsystem: "controller",
			Namespace: "saiki",
			Name:      "processing_errors",
			Help:      "Count of how many errors while processing items.",
		},
	)
)

Functions

func New

func New(ctx context.Context, kubeClient kubernetes.Interface, dynamicClient dynamic.Interface, options ...OptionFunc) *operator

func NewFromEnv

func NewFromEnv(ctx context.Context, kubeClient kubernetes.Interface, dynamicClient dynamic.Interface) (*operator, error)

Types

type OptionFunc

type OptionFunc func(*operator)

func WithBackupPolicy

func WithBackupPolicy(b policy.BackupPolicy) OptionFunc

func WithFlusher

func WithFlusher(flusher flusher.Flusher) OptionFunc

func WithHTTPServerPort

func WithHTTPServerPort(port int) OptionFunc

func WithMetricsHandler

func WithMetricsHandler(path string) OptionFunc

func WithPurger

func WithPurger(purger purger.Purger) OptionFunc

func WithReadinessHandler

func WithReadinessHandler(path string) OptionFunc

func WithReapInterval

func WithReapInterval(interval time.Duration) OptionFunc

func WithReaper

func WithReaper(reaper reaper.Reaper) OptionFunc

func WithStorer

func WithStorer(s store.Storer) OptionFunc

func WithThreadiness

func WithThreadiness(threadiness int) OptionFunc

Directories

Path Synopsis
cache is an implementation of
cache is an implementation of

Jump to

Keyboard shortcuts

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