attachment

package
v1.2.7 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2020 License: Apache-2.0 Imports: 8 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package attachment to manage Kubernetes storage attach events.

Index

Constants

View Source
const (
	CustomResourceName       = "volume"
	CustomResourceNamePlural = "volumes"
)

Variables

VolumeResource represents the Volume custom resource object

Functions

This section is empty.

Types

type Attachment

type Attachment interface {
	Create(volumeAttachment *rookalpha.Volume) error
	Get(namespace, name string) (*rookalpha.Volume, error)
	List(namespace string) (*rookalpha.VolumeList, error)
	Update(volumeAttachment *rookalpha.Volume) error
	Delete(namespace, name string) error
}

Attachment handles custom resource Volume storage operations.

func New

func New(context *clusterd.Context) (Attachment, error)

CreateController creates a new controller for volume attachment

type MockAttachment

type MockAttachment struct {
	MockCreate func(volumeAttachment *rookalpha.Volume) error
	MockGet    func(namespace, name string) (*rookalpha.Volume, error)
	MockList   func(namespace string) (*rookalpha.VolumeList, error)
	MockUpdate func(volumeAttachment *rookalpha.Volume) error
	MockDelete func(namespace, name string) error
}

func (*MockAttachment) Create

func (m *MockAttachment) Create(volumeAttachment *rookalpha.Volume) error

func (*MockAttachment) Delete

func (m *MockAttachment) Delete(namespace, name string) error

func (*MockAttachment) Get

func (m *MockAttachment) Get(namespace, name string) (*rookalpha.Volume, error)

func (*MockAttachment) List

func (m *MockAttachment) List(namespace string) (*rookalpha.VolumeList, error)

func (*MockAttachment) Update

func (m *MockAttachment) Update(volumeAttachment *rookalpha.Volume) error

Jump to

Keyboard shortcuts

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