Documentation ¶
Overview ¶
Package crd provides the store interface to config resources stored as kubernetes custom resource definitions (CRDs).
Index ¶
- func NewStore(u *url.URL) (store.Store2Backend, error)
- func Register(builders map[string]store.Store2Builder)
- type Store
- func (s *Store) Get(key store.Key) (*store.BackEndResource, error)
- func (s *Store) Init(ctx context.Context, kinds []string) error
- func (s *Store) List() map[store.Key]*store.BackEndResource
- func (s *Store) OnAdd(obj interface{})
- func (s *Store) OnDelete(obj interface{})
- func (s *Store) OnUpdate(oldObj, newObj interface{})
- func (s *Store) Watch(ctx context.Context) (<-chan store.BackendEvent, error)
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) 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.
Click to show internal directories.
Click to hide internal directories.