servicebinding

package
v0.0.0-...-feb569f Latest Latest
Warning

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

Go to latest
Published: May 10, 2017 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrCancelled          = errors.New("stopped")
	ErrNotAServiceBinding = errors.New("not a service binding")
	ErrWatchClosed        = errors.New("watch closed")
)

Functions

func RunLoop

func RunLoop(
	ctx context.Context,
	namespace string,
	binder framework.Binder,
	secretWriter SecretWriterFunc,
	fn WatchServiceBindingFunc,
	updateFn UpdateServiceBindingFunc,
	getSvcBrokerFn refs.ServiceBrokerGetterFunc,
	getSvcClassFn refs.ServiceClassGetterFunc,
	getSvcInstanceFn refs.ServiceInstanceGetterFunc,
) error

RunLoop starts a blocking control loop that watches and takes action on serviceBroker resources.

TODO: remove the namespace param. See https://github.com/deis/steward-framework/issues/30

Types

type SecretWriterFunc

type SecretWriterFunc func(*apiv1.Secret) (*apiv1.Secret, error)

SecretWriterFunc is the function that writes a secret to storage

func NewK8sSecretWriterFunc

func NewK8sSecretWriterFunc(secretsIface v1.SecretInterface) SecretWriterFunc

NewK8sSecretWriterFunc returns a SecretWriterFunc implemented with a Kubernetes client

type UpdateServiceBindingFunc

type UpdateServiceBindingFunc func(*data.ServiceBinding) (*data.ServiceBinding, error)

UpdateServiceBindingFunc is the function that can update a service binding

func NewK8sUpdateServiceBindingFunc

func NewK8sUpdateServiceBindingFunc(cl *dynamic.Client) UpdateServiceBindingFunc

NewK8sUpdateServiceBindingFunc returns an UpdateServiceBindingFunc backed by a Kubernetes client

type WatchServiceBindingFunc

type WatchServiceBindingFunc func(namespace string) (watch.Interface, error)

WatchServiceBindingFunc is the function that returns a watch interface for service binding resources

func NewK8sWatchServiceBindingFunc

func NewK8sWatchServiceBindingFunc(cl *dynamic.Client) WatchServiceBindingFunc

NewK8sWatchServiceBindingFunc returns a WatchServiceBindingFunc backed by a Kubernetes client

Jump to

Keyboard shortcuts

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