crd

package
Version: v0.0.0-...-46d7da7 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2018 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Package crd provides the store interface to config resources stored as kubernetes custom resource definitions (CRDs).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewStore

func NewStore(u *url.URL) (store.Backend, error)

NewStore creates a new Store instance.

func Register

func Register(builders map[string]store.Builder)

Register registers this module as a StoreBackend. Do not use 'init()' for automatic registration; linker will drop the whole module because it looks unused.

func ToBackEndResource

func ToBackEndResource(uns *unstructured.Unstructured) *store.BackEndResource

ToBackEndResource converts an unstructured k8s resource into a mixer backend resource.

Types

type Store

type Store struct {
	*probe.Probe
	// contains filtered or unexported fields
}

Store offers store.StoreBackend interface through kubernetes custom resource definitions.

func (*Store) Get

func (s *Store) Get(key store.Key) (*store.BackEndResource, error)

Get implements store.Backend interface.

func (*Store) Init

func (s *Store) Init(kinds []string) error

Init implements store.StoreBackend interface.

func (*Store) List

func (s *Store) List() map[store.Key]*store.BackEndResource

List implements store.Backend interface.

func (*Store) OnAdd

func (s *Store) OnAdd(obj interface{})

OnAdd implements cache.ResourceEventHandler interface.

func (*Store) OnDelete

func (s *Store) OnDelete(obj interface{})

OnDelete implements cache.ResourceEventHandler interface.

func (*Store) OnUpdate

func (s *Store) OnUpdate(oldObj, newObj interface{})

OnUpdate implements cache.ResourceEventHandler interface.

func (*Store) Stop

func (s *Store) Stop()

Stop implements store.Backend interface.

func (*Store) Watch

func (s *Store) Watch() (<-chan store.BackendEvent, error)

Watch implements store.Backend interface.

Source Files

Jump to

Keyboard shortcuts

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