sentry

package
v0.0.0-...-f2ed473 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotReady  = fmt.Errorf("NotReady")
	ErrNotSynced = fmt.Errorf("NotSynced")
)

Functions

This section is empty.

Types

type Controller

type Controller struct {
	*Options
	// contains filtered or unexported fields
}

func (*Controller) Inspect

func (ctl *Controller) Inspect(kind, key string) error

func (*Controller) OnAdd

func (ctl *Controller) OnAdd(obj interface{})

func (*Controller) OnDelete

func (ctl *Controller) OnDelete(obj interface{})

func (*Controller) OnUpdate

func (ctl *Controller) OnUpdate(before, after interface{})

func (*Controller) Run

func (ctl *Controller) Run(workers int, stopCh <-chan struct{})

type Option

type Option func(*Options)

func DisableRevision

func DisableRevision() Option

func EnableDebug

func EnableDebug() Option

func IncludeNamespaces

func IncludeNamespaces(namespaces ...string) Option

func IncludeResources

func IncludeResources(resources ...string) Option

func WithExcludes

func WithExcludes(excludes []*regexp.Regexp) Option

func WithIgnoreCreatedBefore

func WithIgnoreCreatedBefore(d time.Duration) Option

func WithIncludes

func WithIncludes(includes []*regexp.Regexp) Option

func WithKeyFunc

func WithKeyFunc(kf func(interface{}) (string, error)) Option

func WithTimeFormat

func WithTimeFormat(tf string) Option

type Options

type Options struct {
	KeyFunc func(interface{}) (string, error)

	TimeFormat string

	InitBackoff time.Duration
	MaxBackoff  time.Duration
	MaxRetries  int

	IgnoreCreatedBefore time.Duration

	Excludes []*regexp.Regexp
	Includes []*regexp.Regexp

	// Namespaces, watch only these namespaces, default all
	IncludeNamespaces map[string]bool
	// Resources, watch only these resources, default all
	// Support Deployment, StatefulSet, DaemonSet
	IncludeResources map[string]bool

	Debug          bool
	EnableRevision bool
}

Jump to

Keyboard shortcuts

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