controller

package
v0.0.0-...-8323bfd Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2018 License: Apache-2.0 Imports: 45 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CONFIG_MOUNT_PATH = "/usr/local/etc/redis/"
)

Variables

View Source
var (
	AnalyticsClientID string
	EnableAnalytics   = true
	LoggerOptions     golog.Options
)

Functions

This section is empty.

Types

type Controller

type Controller struct {
	amc.Config
	*amc.Controller
	// contains filtered or unexported fields
}

func New

func New(
	client kubernetes.Interface,
	apiExtKubeClient crd_cs.ApiextensionsV1beta1Interface,
	extClient cs.Interface,
	dynamicClient dynamic.Interface,
	promClient pcm.MonitoringV1Interface,
	opt amc.Config,
) *Controller

func (*Controller) EnsureCustomResourceDefinitions

func (c *Controller) EnsureCustomResourceDefinitions() error

EnsureCustomResourceDefinitions ensures CRD for MySQl, DormantDatabase

func (*Controller) Init

func (c *Controller) Init() error

InitInformer initializes Redis, DormantDB amd Snapshot watcher

func (*Controller) Run

func (c *Controller) Run(stopCh <-chan struct{})

Blocks caller. Intended to be called as a Go routine.

func (*Controller) RunControllers

func (c *Controller) RunControllers(stopCh <-chan struct{})

RunControllers runs queue.worker

func (*Controller) StartAndRunControllers

func (c *Controller) StartAndRunControllers(stopCh <-chan struct{})

StartAndRunControllers starts InformetFactory and runs queue.worker

func (*Controller) WaitUntilPaused

func (c *Controller) WaitUntilPaused(drmn *api.DormantDatabase) error

func (*Controller) WipeOutDatabase

func (c *Controller) WipeOutDatabase(drmn *api.DormantDatabase) error

WipeOutDatabase is an Interface of *amc.Controller. It verifies and deletes secrets and other left overs of DBs except Snapshot and PVC.

type OperatorConfig

type OperatorConfig struct {
	amc.Config

	ClientConfig     *rest.Config
	KubeClient       kubernetes.Interface
	APIExtKubeClient crd_cs.ApiextensionsV1beta1Interface
	DBClient         cs.Interface
	DynamicClient    dynamic.Interface
	PromClient       pcm.MonitoringV1Interface
	CronController   snapc.CronControllerInterface
}

func NewOperatorConfig

func NewOperatorConfig(clientConfig *rest.Config) *OperatorConfig

func (*OperatorConfig) New

func (c *OperatorConfig) New() (*Controller, error)

Jump to

Keyboard shortcuts

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