crd

package
v0.0.0-...-6472126 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2017 License: Apache-2.0, Apache-2.0 Imports: 17 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.Store2Backend, error)

NewStore creates a new Store instance.

func Register

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

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

Types

type Store

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

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

func (*Store) Get

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

Get implements store.Store2Backend interface.

func (*Store) Init

func (s *Store) Init(ctx context.Context, kinds []string) error

Init implements store.Store2Backend interface.

func (*Store) List

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

List implements store.Store2Backend 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) Watch

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

Watch implements store.Store2Backend interface.

Jump to

Keyboard shortcuts

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