Documentation ¶
Index ¶
- Constants
- type Client
- type ISCSIService
- func (s *ISCSIService) AddLogicalUnit(ctx context.Context, iqn iscsi.Iqn, volume *common.VolumeConfig) (*common.VolumeConfig, error)
- func (s *ISCSIService) Create(ctx context.Context, config *iscsi.ResourceConfig) (*iscsi.ResourceConfig, error)
- func (s *ISCSIService) Delete(ctx context.Context, iqn iscsi.Iqn) error
- func (s *ISCSIService) DeleteLogicalUnit(ctx context.Context, iqn iscsi.Iqn, lun int) error
- func (s *ISCSIService) Get(ctx context.Context, iqn iscsi.Iqn) (*iscsi.ResourceConfig, error)
- func (s *ISCSIService) GetAll(ctx context.Context) ([]*iscsi.ResourceConfig, error)
- func (s *ISCSIService) GetLogicalUnit(ctx context.Context, iqn iscsi.Iqn, lun int) (*common.VolumeConfig, error)
- func (s *ISCSIService) Start(ctx context.Context, iqn iscsi.Iqn) (*iscsi.ResourceConfig, error)
- func (s *ISCSIService) Stop(ctx context.Context, iqn iscsi.Iqn) (*iscsi.ResourceConfig, error)
- type LeveledLogger
- type LogLevel
- type Logger
- type NFSService
- func (s *NFSService) Create(ctx context.Context, config *nfs.ResourceConfig) (*nfs.ResourceConfig, error)
- func (s *NFSService) Delete(ctx context.Context, name string) error
- func (s *NFSService) Get(ctx context.Context, name string) (*nfs.ResourceConfig, error)
- func (s *NFSService) GetAll(ctx context.Context) ([]*nfs.ResourceConfig, error)
- func (s *NFSService) Start(ctx context.Context, name string) (*nfs.ResourceConfig, error)
- func (s *NFSService) Stop(ctx context.Context, name string) (*nfs.ResourceConfig, error)
- type NvmeOfService
- func (s *NvmeOfService) AddVolume(ctx context.Context, nqn nvmeof.Nqn, volume *common.VolumeConfig) (*common.VolumeConfig, error)
- func (s *NvmeOfService) Create(ctx context.Context, config *nvmeof.ResourceConfig) (*nvmeof.ResourceConfig, error)
- func (s *NvmeOfService) Delete(ctx context.Context, nqn nvmeof.Nqn) error
- func (s *NvmeOfService) DeleteVolume(ctx context.Context, nqn nvmeof.Nqn, volume int) error
- func (s *NvmeOfService) Get(ctx context.Context, nqn nvmeof.Nqn) (*nvmeof.ResourceConfig, error)
- func (s *NvmeOfService) GetAll(ctx context.Context) ([]nvmeof.ResourceConfig, error)
- func (s *NvmeOfService) GetVolume(ctx context.Context, nqn nvmeof.Nqn, lun int) (*common.VolumeConfig, error)
- func (s *NvmeOfService) Start(ctx context.Context, nqn nvmeof.Nqn) (*nvmeof.ResourceConfig, error)
- func (s *NvmeOfService) Stop(ctx context.Context, nqn nvmeof.Nqn) (*nvmeof.ResourceConfig, error)
- type Option
- type Status
- type StatusService
- type TestLogger
Constants ¶
View Source
const (
// NotFoundError is the error type returned in case of a 404 error. This is required to test for this kind of error.
NotFoundError = clientError("404 Not Found")
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Iscsi *ISCSIService Nfs *NFSService NvmeOf *NvmeOfService Status *StatusService // contains filtered or unexported fields }
type ISCSIService ¶
type ISCSIService struct {
// contains filtered or unexported fields
}
func (*ISCSIService) AddLogicalUnit ¶
func (s *ISCSIService) AddLogicalUnit(ctx context.Context, iqn iscsi.Iqn, volume *common.VolumeConfig) (*common.VolumeConfig, error)
func (*ISCSIService) Create ¶
func (s *ISCSIService) Create(ctx context.Context, config *iscsi.ResourceConfig) (*iscsi.ResourceConfig, error)
func (*ISCSIService) DeleteLogicalUnit ¶
func (*ISCSIService) Get ¶
func (s *ISCSIService) Get(ctx context.Context, iqn iscsi.Iqn) (*iscsi.ResourceConfig, error)
func (*ISCSIService) GetAll ¶
func (s *ISCSIService) GetAll(ctx context.Context) ([]*iscsi.ResourceConfig, error)
func (*ISCSIService) GetLogicalUnit ¶
func (s *ISCSIService) GetLogicalUnit(ctx context.Context, iqn iscsi.Iqn, lun int) (*common.VolumeConfig, error)
func (*ISCSIService) Start ¶
func (s *ISCSIService) Start(ctx context.Context, iqn iscsi.Iqn) (*iscsi.ResourceConfig, error)
func (*ISCSIService) Stop ¶
func (s *ISCSIService) Stop(ctx context.Context, iqn iscsi.Iqn) (*iscsi.ResourceConfig, error)
type LeveledLogger ¶
type LeveledLogger interface { Errorf(string, ...interface{}) Infof(string, ...interface{}) Debugf(string, ...interface{}) Warnf(string, ...interface{}) }
LeveledLogger interface implements the basic methods that a logger library needs
type Logger ¶
type Logger interface {
Printf(string, ...interface{})
}
Logger represents a standard logger interface
type NFSService ¶
type NFSService struct {
// contains filtered or unexported fields
}
func (*NFSService) Create ¶
func (s *NFSService) Create(ctx context.Context, config *nfs.ResourceConfig) (*nfs.ResourceConfig, error)
func (*NFSService) Get ¶
func (s *NFSService) Get(ctx context.Context, name string) (*nfs.ResourceConfig, error)
func (*NFSService) GetAll ¶
func (s *NFSService) GetAll(ctx context.Context) ([]*nfs.ResourceConfig, error)
func (*NFSService) Start ¶
func (s *NFSService) Start(ctx context.Context, name string) (*nfs.ResourceConfig, error)
func (*NFSService) Stop ¶
func (s *NFSService) Stop(ctx context.Context, name string) (*nfs.ResourceConfig, error)
type NvmeOfService ¶
type NvmeOfService struct {
// contains filtered or unexported fields
}
func (*NvmeOfService) AddVolume ¶
func (s *NvmeOfService) AddVolume(ctx context.Context, nqn nvmeof.Nqn, volume *common.VolumeConfig) (*common.VolumeConfig, error)
func (*NvmeOfService) Create ¶
func (s *NvmeOfService) Create(ctx context.Context, config *nvmeof.ResourceConfig) (*nvmeof.ResourceConfig, error)
func (*NvmeOfService) DeleteVolume ¶
func (*NvmeOfService) Get ¶
func (s *NvmeOfService) Get(ctx context.Context, nqn nvmeof.Nqn) (*nvmeof.ResourceConfig, error)
func (*NvmeOfService) GetAll ¶
func (s *NvmeOfService) GetAll(ctx context.Context) ([]nvmeof.ResourceConfig, error)
func (*NvmeOfService) GetVolume ¶
func (s *NvmeOfService) GetVolume(ctx context.Context, nqn nvmeof.Nqn, lun int) (*common.VolumeConfig, error)
func (*NvmeOfService) Start ¶
func (s *NvmeOfService) Start(ctx context.Context, nqn nvmeof.Nqn) (*nvmeof.ResourceConfig, error)
func (*NvmeOfService) Stop ¶
func (s *NvmeOfService) Stop(ctx context.Context, nqn nvmeof.Nqn) (*nvmeof.ResourceConfig, error)
type Option ¶
Option configures a Client
type StatusService ¶ added in v1.3.0
type StatusService struct {
// contains filtered or unexported fields
}
type TestLogger ¶
type TestLogger interface {
Logf(string, ...interface{})
}
TestLogger represents a logger interface used in tests, as in testing.T
Click to show internal directories.
Click to hide internal directories.