Documentation
¶
Index ¶
- func ConfigureVolume(p Pooler, vol Volumer, size int64, format bool, acs volaccess.T, shared bool, ...) error
- func DiskName(p Pooler, vol Volumer) string
- func Driver(t string) func() Pooler
- func GetMappings(ctx context.Context, p ArrayPooler, nodes []string, pathType string) (array.Mappings, error)
- func GetPaths(ctx context.Context, p ArrayPooler, nodes []string, pathType string) (san.Paths, error)
- func HasAccess(p Pooler, acs volaccess.T) bool
- func HasCapability(p Pooler, s Capability) bool
- func InitData()
- func MappingsFromPaths(paths san.Paths) (array.Mappings, error)
- func MountPointFromName(name string) string
- type ArrayPooler
- type BlkTranslater
- type By
- type Capabilities
- type Capability
- type Config
- type Data
- type DataElement
- type Dataer
- type Disk
- type Lookup
- type Pooler
- type Status
- type StatusItem
- type StatusList
- type T
- func (t *T) AddFS(name string, shared bool, fsIndex int, diskIndex int, onDisk string) []string
- func (t *T) Config() Config
- func (t *T) FSType() string
- func (t *T) GetBool(s string) bool
- func (t *T) GetInt(s string) int
- func (t *T) GetSize(s string) *int64
- func (t *T) GetString(s string) string
- func (t *T) GetStringAs(s, nodename string) string
- func (t *T) GetStrings(s string) []string
- func (t *T) Mappings() map[string]string
- func (t *T) MkblkOptions() string
- func (t *T) MkfsOptions() string
- func (t *T) MntOptions() string
- func (t T) Name() string
- func (t T) Separator() string
- func (t *T) SetConfig(c Config)
- func (t *T) SetDriver(driver string)
- func (t *T) SetName(name string)
- func (t T) Type() string
- type Translater
- type Usage
- type VolumeStatus
- type VolumeStatusList
- type Volumer
- type WeightedPools
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigureVolume ¶
func GetMappings ¶
func HasCapability ¶
func HasCapability(p Pooler, s Capability) bool
func MountPointFromName ¶
Types ¶
type ArrayPooler ¶
type BlkTranslater ¶
type Capabilities ¶
type Capabilities []Capability
func (Capabilities) String ¶
func (t Capabilities) String() string
func (Capabilities) StringSlice ¶
func (t Capabilities) StringSlice() []string
type Capability ¶
type Capability string
const ( CapBlk Capability = "blk" CapFile Capability = "file" CapMove Capability = "move" CapROO Capability = "roo" CapROX Capability = "rox" CapRWO Capability = "rwo" CapRWX Capability = "rwx" CapSnap Capability = "snap" CapVolatile Capability = "volatile" )
type Data ¶
Data defines a shared holder for all pool Dataer
var ( // StatusData is the package data holder for all instances statuses StatusData *Data[Status] )
func (*Data[T]) Get ¶
func (c *Data[T]) Get(name, node string) *T
Get returns a pool data or nil if data is not found
func (*Data[T]) GetAll ¶
func (c *Data[T]) GetAll() []DataElement[T]
GetAll returns all pool data as a list of DataElements
func (*Data[T]) GetByName ¶
func (c *Data[T]) GetByName(name string) []DataElement[T]
GetByName returns pool instances on a specific node as a list of DataElements
func (*Data[T]) GetByNode ¶
func (c *Data[T]) GetByNode(nodename string) []DataElement[T]
GetByNode returns pool instances on a specific node as a list of DataElements
type DataElement ¶
type Lookup ¶
type Lookup struct {
Name string
Type string
Access volaccess.T
Size int64
Format bool
Usage bool
Volatile bool
Nodes []string
// contains filtered or unexported fields
}
func (Lookup) ConfigureVolume ¶
type Pooler ¶
type Status ¶
type Status struct {
Usage
Capabilities Capabilities `json:"capabilities"`
Errors []string `json:"errors"`
Head string `json:"head"`
Type string `json:"type"`
UpdatedAt time.Time `json:"updated_at"`
VolumeCount int `json:"volume_count"`
}
func (*Status) HasCapability ¶
func (t *Status) HasCapability(s Capability) bool
type StatusItem ¶
type StatusList ¶
type StatusList []StatusItem
func NewStatusList ¶
func NewStatusList() StatusList
func (StatusList) Add ¶
func (t StatusList) Add(ctx context.Context, p Pooler, withUsage bool) StatusList
func (StatusList) Len ¶
func (t StatusList) Len() int
func (StatusList) Less ¶
func (t StatusList) Less(i, j int) bool
func (StatusList) Swap ¶
func (t StatusList) Swap(i, j int)
type T ¶
type T struct {
// contains filtered or unexported fields
}
func (*T) GetStringAs ¶
func (*T) GetStrings ¶
func (*T) MkblkOptions ¶
func (*T) MkfsOptions ¶
func (*T) MntOptions ¶
type Translater ¶
type VolumeStatus ¶
type VolumeStatusList ¶
type VolumeStatusList []VolumeStatus
func (VolumeStatusList) Len ¶
func (t VolumeStatusList) Len() int
func (VolumeStatusList) Less ¶
func (t VolumeStatusList) Less(i, j int) bool
func (VolumeStatusList) Swap ¶
func (t VolumeStatusList) Swap(i, j int)
type WeightedPools ¶
type WeightedPools []Pooler
Click to show internal directories.
Click to hide internal directories.