Documentation ¶
Index ¶
- func IsInvalidConfig(err error) bool
- type Config
- type Storage
- func (s *Storage) Boot(ctx context.Context) error
- func (s *Storage) Delete(ctx context.Context, k microstorage.K) error
- func (s *Storage) Exists(ctx context.Context, k microstorage.K) (bool, error)
- func (s *Storage) List(ctx context.Context, k microstorage.K) ([]microstorage.KV, error)
- func (s *Storage) Put(ctx context.Context, kv microstorage.KV) error
- func (s *Storage) Search(ctx context.Context, k microstorage.K) (microstorage.KV, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsInvalidConfig ¶
IsInvalidConfig asserts invalidConfigError.
Types ¶
type Config ¶
type Config struct { G8sClient versioned.Interface K8sClient kubernetes.Interface Logger micrologger.Logger Name string Namespace *corev1.Namespace }
type Storage ¶
type Storage struct {
// contains filtered or unexported fields
}
func New ¶
New creates an uninitialized instance of Storage. It is required to call Boot before running any read/write operations against the returned Storage instance.
func (*Storage) Boot ¶
Boot initializes the Storage by ensuring Kubernetes resources used by the Storage are in place. It is safe to call Boot more than once.
func (*Storage) List ¶
func (s *Storage) List(ctx context.Context, k microstorage.K) ([]microstorage.KV, error)
func (*Storage) Search ¶
func (s *Storage) Search(ctx context.Context, k microstorage.K) (microstorage.KV, error)
Click to show internal directories.
Click to hide internal directories.