Documentation
¶
Index ¶
- Variables
- type CephProvider
- func (c *CephProvider) Attach(ctx context.Context, volId string) (string, error)
- func (c *CephProvider) CreateVolume(ctx context.Context, volId string, size int64) (string, error)
- func (c *CephProvider) DeleteVolume(ctx context.Context, volId string) error
- func (c *CephProvider) Detach(ctx context.Context, volId string) error
- func (c *CephProvider) GetDetail() string
- func (c *CephProvider) GetImageName(volId string) string
- func (c *CephProvider) GetMapDevice(volId string) (string, error)
- func (c *CephProvider) GetVolumeType() VolumeType
- func (c *CephProvider) HasVolume(volId string) (bool, error)
- func (c *CephProvider) Resize(volId string, size int64) error
- type VolumeProvider
- type VolumeType
Constants ¶
This section is empty.
Variables ¶
View Source
var ( NoSuchFileErr = errors.New("no such file or directory") NotMapDevice = errors.New("not a mapped image or snapshot") )
Functions ¶
This section is empty.
Types ¶
type CephProvider ¶
type CephProvider struct {
// contains filtered or unexported fields
}
func NewCephProvider ¶
func NewCephProvider(timeout int, poolName string) *CephProvider
func (*CephProvider) CreateVolume ¶
func (*CephProvider) DeleteVolume ¶
func (c *CephProvider) DeleteVolume(ctx context.Context, volId string) error
func (*CephProvider) Detach ¶
func (c *CephProvider) Detach(ctx context.Context, volId string) error
func (*CephProvider) GetDetail ¶
func (c *CephProvider) GetDetail() string
func (*CephProvider) GetImageName ¶
func (c *CephProvider) GetImageName(volId string) string
func (*CephProvider) GetMapDevice ¶
func (c *CephProvider) GetMapDevice(volId string) (string, error)
func (*CephProvider) GetVolumeType ¶
func (c *CephProvider) GetVolumeType() VolumeType
type VolumeProvider ¶
type VolumeProvider interface { GetVolumeType() VolumeType GetDetail() string CreateVolume(ctx context.Context, volId string, size int64) (string, error) DeleteVolume(ctx context.Context, volId string) error Attach(ctx context.Context, volId string) (string, error) Detach(ctx context.Context, volId string) error Resize(volId string, size int64) error GetMapDevice(volId string) (string, error) HasVolume(volId string) (bool, error) }
Click to show internal directories.
Click to hide internal directories.