syncer

package
v0.0.0-...-1ac4f16 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2019 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WaitAtMost

func WaitAtMost(fn func() (bool, error), duration time.Duration) error

WaitAtMost waits for the given amount of time until the given function will return true

Types

type Controller

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

Controller populates local storage with all Application custom resources created in k8s cluster.

func New

func New(applicationInformer informers.ApplicationInformer, appUpserter applicationUpserter, appRemover applicationRemover, scRelistRequester scRelistRequester, log logrus.FieldLogger) *Controller

New creates new application controller

func (*Controller) Run

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

Run starts the controller

type RelistRequester

type RelistRequester struct {
	// contains filtered or unexported fields
}

RelistRequester informs the Service Catalog that given Service Broker should be relisted. Due to performance reason, many relist requests which happen during the period defined in `reListDurationWindow` result in a single Service Catalog relist trigger.

func NewRelistRequester

func NewRelistRequester(brokerSyncer brokerSyncer, reListDuration time.Duration, log logrus.FieldLogger) *RelistRequester

NewRelistRequester returns new instance of RelistRequester

func (*RelistRequester) RequestRelist

func (r *RelistRequester) RequestRelist()

RequestRelist informs the Service Catalog that Broker should be relisted.

func (*RelistRequester) Run

func (r *RelistRequester) Run(stopCh <-chan struct{})

Run runs worker which executing relist operation

type ServiceBrokerSync

type ServiceBrokerSync struct {
	// contains filtered or unexported fields
}

ServiceBrokerSync provide services to sync the ServiceBrokers

func NewServiceBrokerSyncer

func NewServiceBrokerSyncer(serviceBrokerGetter v1beta12.ServiceBrokersGetter) *ServiceBrokerSync

NewServiceBrokerSyncer allows to sync the ServiceBrokers

func (*ServiceBrokerSync) Sync

func (r *ServiceBrokerSync) Sync(maxSyncRetries int) error

Sync syncs the ServiceBrokers

func (*ServiceBrokerSync) SyncBroker

func (r *ServiceBrokerSync) SyncBroker(namespace string) error

SyncBroker syncing the default AB ns-broker in the given namespace

type TimeAfterProvider

type TimeAfterProvider func(d time.Duration) <-chan time.Time

TimeAfterProvider is a provider for time.After. If not initialised defaults to time.After implementation for stdlib. It's intended to facilitate testing without time dependency.

func (TimeAfterProvider) After

func (p TimeAfterProvider) After(d time.Duration) <-chan time.Time

After calls attached After implementation.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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