Documentation
¶
Index ¶
- Variables
- func LinearProbe(total, start, attempt int) int
- func QuadraticProbe(total, start, attempt int) int
- func RandomProbe(total, _start, _attempt int) int
- func RandomProbeWithRand(rng *rand.Rand) func(total, start, attempt int) int
- type AppendChunkOptions
- type ChooseVolumeOptions
- type Chunk
- type ChunkHandle
- type ChunkID
- func (id ChunkID) Bytes() []byte
- func (id ChunkID) MarshalBinary() ([]byte, error)
- func (id ChunkID) MarshalText() ([]byte, error)
- func (id ChunkID) NodeID() NodeID
- func (id ChunkID) Sequence() uint16
- func (id ChunkID) String() string
- func (id ChunkID) Time() time.Time
- func (id ChunkID) UnixMilli() int64
- func (id *ChunkID) UnmarshalBinary(data []byte) error
- func (id *ChunkID) UnmarshalText(data []byte) error
- func (id ChunkID) VolumeID() VolumeID
- type ChunkIDGenerator
- type ChunkRangeReader
- type ChunkReader
- type ChunkReaderAt
- type ChunkRepository
- type ChunkState
- type ChunkStorage
- type CreateChunkOptions
- type DeletedChunk
- func (c *DeletedChunk) CreatedAt() time.Time
- func (c *DeletedChunk) DeletedAt() (time.Time, bool)
- func (c *DeletedChunk) ExpiresAt() (time.Time, bool)
- func (c *DeletedChunk) ID() ChunkID
- func (c *DeletedChunk) Size() (int64, bool)
- func (*DeletedChunk) State() ChunkState
- func (c *DeletedChunk) UpdatedAt() (time.Time, bool)
- func (c *DeletedChunk) Version() (uint64, bool)
- func (c *DeletedChunk) WriterKey() []byte
- type FileStoreFormat
- type FilesystemType
- type IOKitIOBlockStorageDriverStatistics
- type InterconnectType
- type LinuxBlockLayerStatistics
- type MediumType
- type NodeClaim
- type NodeClaimRegistry
- type NodeClaimRepository
- type NodeID
- type NodeIDProvider
- type NodeLabelPublisher
- type NodeLabelSource
- type NodePeer
- type NodePeerGRPC
- type NodePeerResolver
- type NodePresence
- type NodePresenceGRPC
- type NodePresencePublisher
- type NodeSeed
- type NodeSeedGenerator
- type NodeSeedRepository
- type PendingChunk
- func (c *PendingChunk) CreatedAt() time.Time
- func (c *PendingChunk) DeletedAt() (time.Time, bool)
- func (c *PendingChunk) ExpiresAt() (time.Time, bool)
- func (c *PendingChunk) ID() ChunkID
- func (c *PendingChunk) Size() (int64, bool)
- func (*PendingChunk) State() ChunkState
- func (c *PendingChunk) UpdatedAt() (time.Time, bool)
- func (c *PendingChunk) Version() (uint64, bool)
- func (c *PendingChunk) WriterKey() []byte
- type ProtocolType
- type PutChunkOptions
- type ReadyChunk
- func (c *ReadyChunk) CreatedAt() time.Time
- func (c *ReadyChunk) DeletedAt() (time.Time, bool)
- func (c *ReadyChunk) ExpiresAt() (time.Time, bool)
- func (c *ReadyChunk) ID() ChunkID
- func (c *ReadyChunk) Size() (int64, bool)
- func (*ReadyChunk) State() ChunkState
- func (c *ReadyChunk) UpdatedAt() (time.Time, bool)
- func (c *ReadyChunk) Version() (uint64, bool)
- func (c *ReadyChunk) WriterKey() []byte
- type Sample
- type ShrinkChunkToFitOptions
- type SpaceUtilizationStatistics
- type VolumeCharacteristics
- type VolumeCharacteristicsProvider
- type VolumeChooser
- type VolumeHandle
- type VolumeHealth
- type VolumeID
- type VolumeIDCounter
- type VolumeInfo
- type VolumeLabelPublisher
- type VolumeLabelSource
- type VolumeOTelAttributeProvider
- type VolumeSet
- type VolumeStatisticsProvider
- type VolumeStatus
- type VolumeStatusProvider
- type VolumeStructuredLoggingFieldsProvider
- type ZoningType
Constants ¶
This section is empty.
Variables ¶
var ( // ERROR_CODE_INTERNAL (catch‑all when we can’t classify better) ErrInternal = errors.New("internal error") // ERROR_CODE_CANCELED ErrCanceled = errors.New("canceled") // ERROR_CODE_DEADLINE_EXCEEDED ErrDeadlineExceeded = errors.New("deadline exceeded") // ERROR_CODE_CHUNK_NOT_FOUND ErrChunkNotFound = errors.New("not found") // ERROR_CODE_CHUNK_ALREADY_EXISTS ErrChunkAlreadyExists = errors.New("already exists") // ERROR_CODE_CHUNK_CORRUPTED ErrChunkCorrupted = errors.New("chunk corrupted") // ERROR_CODE_CHUNK_WRITE_INCOMPLETE ErrChunkWriteIncomplete = errors.New("incomplete write") // ERROR_CODE_INVALID_OPERATION (e.g. deleted/pending when we expect ready) ErrChunkInvalidOperation = errors.New("invalid operation") // ERROR_CODE_CHUNK_INVALID_VERSION (for optimistic locking / append out-of-sync) ErrChunkInvalidVersion = errors.New("invalid version") // ERROR_CODE_CHUNK_INVALID_RANGE (bad offsets/lengths, negative sizes, etc.) ErrChunkInvalidRange = errors.New("invalid range") // ERROR_CODE_CHUNK_INVALID_ID (bad chunk ID format, etc.) ErrChunkInvalidID = errors.New("invalid id") // ERROR_CODE_CLOCK_NOT_MONOTONIC (clock moved backwards) ErrClockNotMonotonic = errors.New("non-monotonic clock") // ERROR_CODE_VOLUME_DEGRADED ErrVolumeDegraded = errors.New("volume degraded") // ERROR_CODE_VOLUME_FAILED ErrVolumeFailed = errors.New("volume failed") ErrNodeClaimNotFound = errors.New("node claim not found") ErrNodeClaimInvalid = errors.New("node claim invalid") ErrNodeClaimConflict = errors.New("node claim conflict") ErrNodeSeedNotFound = errors.New("node seed not found") ErrFileStoreVolumeAlreadyInitialized = errors.New("file store volume already initialized") ErrFileStoreVolumeNotInitialized = errors.New("file store volume not initialized") ErrFileStoreVolumeCorrupt = errors.New("file store volume corrupt") ErrFileStoreVolumeVersionMismatch = errors.New("file store volume version mismatch") ErrNodePeerNotFound = errors.New("node peer not found") )
Functions ¶
func LinearProbe ¶
Linear implements a linear probing strategy. It calculates the next index to probe based on the total number of items, the starting index, and the current attempt number.
func QuadraticProbe ¶
Quadratic calculates the next index to probe using quadratic probing. It takes the total number of slots, the starting index, and the current attempt number. It returns the next index to probe, or -1 if total is less than or equal to 0.
func RandomProbe ¶
Random selects a random index from the available total number of targets. It ignores the start and attempt parameters. If total is less than or equal to zero, it returns -1.
Types ¶
type AppendChunkOptions ¶
type AppendChunkOptions struct {
MinTailSlackLength int64
}
type ChooseVolumeOptions ¶
type ChunkHandle ¶
type ChunkHandle interface {
io.Closer
OpenReader(ctx context.Context) (ChunkReader, error)
OpenRangeReader(ctx context.Context, offset, length int64) (ChunkRangeReader, error)
OpenReaderAt(ctx context.Context) (ChunkReaderAt, error)
}
type ChunkID ¶
type ChunkID [16]byte
func NewChunkID ¶
func ParseChunkID ¶
func (ChunkID) MarshalBinary ¶
func (ChunkID) MarshalText ¶
func (*ChunkID) UnmarshalBinary ¶
func (*ChunkID) UnmarshalText ¶
type ChunkIDGenerator ¶
type ChunkRepository ¶
type ChunkState ¶
type ChunkState int
const ( ChunkStateUnknown ChunkState = iota ChunkStatePending ChunkStateReady ChunkStateDeleted )
type ChunkStorage ¶
type ChunkStorage interface {
Open(ctx context.Context, id ChunkID) (ChunkHandle, error)
Create(ctx context.Context, id ChunkID, opts CreateChunkOptions) error
Put(ctx context.Context, id ChunkID, r io.Reader, n int64, opts PutChunkOptions) error
Append(ctx context.Context, id ChunkID, knownSize int64, r io.Reader, n int64, opts AppendChunkOptions) error
Delete(ctx context.Context, id ChunkID) error
ShrinkToFit(ctx context.Context, id ChunkID, knownSize int64, opts ShrinkChunkToFitOptions) error
Exists(ctx context.Context, id ChunkID) (bool, error)
}
type CreateChunkOptions ¶
type CreateChunkOptions struct {
MinTailSlackLength int64
}
type DeletedChunk ¶
type DeletedChunk struct {
// contains filtered or unexported fields
}
func NewDeletedChunk ¶
func (*DeletedChunk) CreatedAt ¶
func (c *DeletedChunk) CreatedAt() time.Time
func (*DeletedChunk) ID ¶
func (c *DeletedChunk) ID() ChunkID
func (*DeletedChunk) Size ¶
func (c *DeletedChunk) Size() (int64, bool)
func (*DeletedChunk) State ¶
func (*DeletedChunk) State() ChunkState
func (*DeletedChunk) Version ¶
func (c *DeletedChunk) Version() (uint64, bool)
func (*DeletedChunk) WriterKey ¶
func (c *DeletedChunk) WriterKey() []byte
type FileStoreFormat ¶
type FileStoreFormat interface {
Initialize(node NodeID, volume VolumeID, path string) error
Stat(path string) (*VolumeInfo, error)
Open(path string) (VolumeHandle, error)
}
type FilesystemType ¶
type FilesystemType string
const ( FilesystemTypeUnknown FilesystemType = "" FilesystemTypeAPFS FilesystemType = "apfs" FilesystemTypeBtrfs FilesystemType = "btrfs" FilesystemTypeExt4 FilesystemType = "ext4" FilesystemTypeHFSPlus FilesystemType = "hfs+" FilesystemTypeNTFS FilesystemType = "ntfs" FilesystemTypeReFS FilesystemType = "refs" FilesystemTypeXFS FilesystemType = "xfs" FilesystemTypeZFS FilesystemType = "zfs" )
func (FilesystemType) String ¶
func (fs FilesystemType) String() string
type IOKitIOBlockStorageDriverStatistics ¶
type IOKitIOBlockStorageDriverStatistics struct {
// Describes the number of bytes read since the block storage driver was instantiated.
//
// This property describes the number of bytes read since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
BytesRead int64 `plist:"Bytes (Read)"`
// Describes the number of bytes written since the block storage driver was instantiated.
//
// This property describes the number of bytes written since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
BytesWritten int64 `plist:"Bytes (Write)"`
// Describes the number of nanoseconds of latency during reads since the block storage driver was instantiated.
//
// This property describes the number of nanoseconds of latency during reads since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
LatentReadTime int64 `plist:"Latency Time (Read)"`
// Describes the number of nanoseconds of latency during writes since the block storage driver was instantiated.
//
// This property describes the number of nanoseconds of latency during writes since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
LatentWriteTime int64 `plist:"Latency Time (Write)"`
// Describes the number of read errors encountered since the block storage driver was instantiated.
//
// This property describes the number of read errors encountered since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
ReadErrors int64 `plist:"Errors (Read)"`
// Describes the number of read retries required since the block storage driver was instantiated.
//
// This property describes the number of read retries required since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
ReadRetries int64 `plist:"Retries (Read)"`
// Describes the number of read operations processed since the block storage driver was instantiated.
//
// This property describes the number of read operations processed since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
Reads int64 `plist:"Operations (Read)"`
// Describes the number of nanoseconds spent performing reads since the block storage driver was instantiated.
//
// This property describes the number of nanoseconds spent performing reads since the block storage driver was instantiated. It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table. It has an OSNumber value.
TotalReadTime int64 `plist:"Total Time (Read)"`
// Describes the number of nanoseconds spent performing writes since the block storage driver was instantiated.
//
// This property describes the number of nanoseconds spent performing writes since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
TotalWriteTime int64 `plist:"Total Time (Write)"`
// Describes the number of write errors encountered since the block storage driver was instantiated.
//
// This property describes the number of write errors encountered since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
WriteErrors int64 `plist:"Errors (Write)"`
// Describes the number of write retries required since the block storage driver was instantiated.
//
// This property describes the number of write retries required since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
WriteRetries int64 `plist:"Retries (Write)"`
// Describes the number of write operations processed since the block storage driver was instantiated.
//
// This property describes the number of write operations processed since the block storage driver was instantiated.
// It is one of the statistic entries listed under the top-level kIOBlockStorageDriverStatisticsKey property table.
// It has an OSNumber value.
Writes int64 `plist:"Operations (Write)"`
}
Statistics from IOKit block storage drivers on Apple platforms.
type InterconnectType ¶
type InterconnectType string
InterconnectType describes the physical or network layer connecting a storage device. The zero value ("") indicates the interconnect type could not be determined.
const ( // InterconnectTypeFibreChannel indicates a Fibre Channel connection. InterconnectTypeFibreChannel InterconnectType = "fibre-channel" // InterconnectTypeFireWire indicates an IEEE 1394 (FireWire) connection. InterconnectTypeFireWire InterconnectType = "firewire" // InterconnectTypeInfiniBand indicates an InfiniBand connection. InterconnectTypeInfiniBand InterconnectType = "infiniband" // InterconnectTypePATA indicates a Parallel ATA (IDE) connection. InterconnectTypePATA InterconnectType = "pata" // InterconnectTypePCIExpress indicates a PCI Express connection. InterconnectTypePCIExpress InterconnectType = "pci-express" // InterconnectTypeRDMA indicates an RDMA connection (e.g., RoCE, iWARP). InterconnectTypeRDMA InterconnectType = "rdma" // InterconnectTypeSAS indicates a Serial Attached SCSI connection. InterconnectTypeSAS InterconnectType = "sas" // InterconnectTypeSATA indicates a Serial ATA connection. InterconnectTypeSATA InterconnectType = "sata" // InterconnectTypeTCP indicates a TCP/IP network connection. InterconnectTypeTCP InterconnectType = "tcp" // InterconnectTypeUSB indicates a USB connection. InterconnectTypeUSB InterconnectType = "usb" // InterconnectTypeVirtIO indicates a VirtIO virtual device. InterconnectTypeVirtIO InterconnectType = "virtio" )
type LinuxBlockLayerStatistics ¶
type LinuxBlockLayerStatistics struct {
// Reads is the number of read operations completed.
Reads int64
// MergedReads is the number of read operations merged.
MergedReads int64
// SectorsRead is the number of sectors read.
SectorsRead int64
// ReadTicks is the total number of milliseconds that read I/O requests have waited on this block device.
// If multiple requests are waiting, this value increases faster than real time.
ReadTicks int64
// Writes is the number of write operations completed.
Writes int64
// MergedWrites is the number of write operations merged.
MergedWrites int64
// SectorsWritten is the number of sectors written.
SectorsWritten int64
// WriteTicks is the total number of milliseconds that write I/O requests have waited on this block device.
// If multiple requests are waiting, this value increases faster than real time.
WriteTicks int64
// InFlight is the number of I/O operations currently in progress.
InFlight int64
// IOTicks is the total number of milliseconds during which the device has had I/O requests queued.
IOTicks int64
// TimeInQueue is the total wait time for all I/O requests, in milliseconds.
TimeInQueue int64
// Discards is the number of discard operations completed.
Discards int64
// MergedDiscards is the number of discard operations merged.
MergedDiscards int64
// SectorsDiscarded is the number of sectors discarded.
SectorsDiscarded int64
// DiscardTicks is the total number of milliseconds that discard I/O requests have waited on this block device.
// If multiple requests are waiting, this value increases faster than real time.
DiscardTicks int64
// Flushes is the number of flush operations completed.
Flushes int64
// FlushTicks is the total number of milliseconds that flush I/O requests have waited on this block device.
// If multiple requests are waiting, this value increases faster than real time.
FlushTicks int64
}
Raw values from /sys/block/<device>/stat
type MediumType ¶
type MediumType string
MediumType describes the physical storage medium. The zero value ("") indicates the medium type could not be determined.
const ( // MediumTypeRotational indicates a spinning disk (HDD). MediumTypeRotational MediumType = "rotational" // MediumTypeSolidState indicates flash storage (SSD). MediumTypeSolidState MediumType = "solid-state" )
type NodeClaimRegistry ¶
type NodeClaimRepository ¶
type NodeIDProvider ¶
type NodeIDProvider interface {
GetNodeID() NodeID
}
type NodeLabelPublisher ¶
type NodeLabelSource ¶
type NodePeer ¶
type NodePeer struct {
ID NodeID
GRPC NodePeerGRPC
}
type NodePeerGRPC ¶
type NodePeerGRPC struct {
URLs []string
}
type NodePeerResolver ¶
type NodePresence ¶
type NodePresence struct {
ID NodeID
Nonce [32]byte
GRPC NodePresenceGRPC
}
func (*NodePresence) Equals ¶
func (p *NodePresence) Equals(other *NodePresence) bool
type NodePresenceGRPC ¶
type NodePresenceGRPC struct {
URLs []string
}
type NodePresencePublisher ¶
type NodePresencePublisher interface {
Publish(presence *NodePresence)
}
type NodeSeedGenerator ¶
type NodeSeedRepository ¶
type PendingChunk ¶
type PendingChunk struct {
// contains filtered or unexported fields
}
func NewPendingChunk ¶
func (*PendingChunk) CreatedAt ¶
func (c *PendingChunk) CreatedAt() time.Time
func (*PendingChunk) ID ¶
func (c *PendingChunk) ID() ChunkID
func (*PendingChunk) Size ¶
func (c *PendingChunk) Size() (int64, bool)
func (*PendingChunk) State ¶
func (*PendingChunk) State() ChunkState
func (*PendingChunk) Version ¶
func (c *PendingChunk) Version() (uint64, bool)
func (*PendingChunk) WriterKey ¶
func (c *PendingChunk) WriterKey() []byte
type ProtocolType ¶
type ProtocolType string
ProtocolType describes the storage command protocol. This determines queuing behavior: ATA has a single queue (depth up to 32 with NCQ), SCSI has a single deep queue, and NVMe has multiple deep queues. The zero value ("") indicates the protocol could not be determined.
const ( // ProtocolTypeATA indicates the ATA command set (used by SATA/PATA devices). ProtocolTypeATA ProtocolType = "ata" // ProtocolTypeSCSI indicates the SCSI command set (used by SAS, USB, FireWire, iSCSI, FC). ProtocolTypeSCSI ProtocolType = "scsi" // ProtocolTypeNVMe indicates the NVMe command set. ProtocolTypeNVMe ProtocolType = "nvme" )
type PutChunkOptions ¶
type PutChunkOptions struct {
MinTailSlackLength int64
}
type ReadyChunk ¶
type ReadyChunk struct {
// contains filtered or unexported fields
}
func NewReadyChunk ¶
func (*ReadyChunk) CreatedAt ¶
func (c *ReadyChunk) CreatedAt() time.Time
func (*ReadyChunk) ID ¶
func (c *ReadyChunk) ID() ChunkID
func (*ReadyChunk) Size ¶
func (c *ReadyChunk) Size() (int64, bool)
func (*ReadyChunk) State ¶
func (*ReadyChunk) State() ChunkState
func (*ReadyChunk) Version ¶
func (c *ReadyChunk) Version() (uint64, bool)
func (*ReadyChunk) WriterKey ¶
func (c *ReadyChunk) WriterKey() []byte
type Sample ¶
type Sample[T any] struct { // The sampled value Value T // A monotonic increasing epoch counter incremented whenever the underlying provider attempts to update stats. Epoch uint64 // The time at which the sample was taken. Time time.Time // Any error encountered while obtaining the sample. Error error }
A sample of a particular statistic type T.
type ShrinkChunkToFitOptions ¶
type ShrinkChunkToFitOptions struct {
MaxTailSlackLength int64
}
type VolumeCharacteristics ¶
type VolumeCharacteristics struct {
DeviceName string
Medium MediumType
Interconnect InterconnectType
Protocol ProtocolType
Vendor string
Model string
SerialNumber string
Filesystem FilesystemType
Zoning ZoningType
}
VolumeCharacteristics describes the physical properties of a storage volume. These characteristics are detected from platform-specific sources (IOKit on macOS, sysfs on Linux) and normalized into a unified representation for labeling and observability purposes.
type VolumeCharacteristicsProvider ¶
type VolumeCharacteristicsProvider interface {
Get() *VolumeCharacteristics
Watch(watchCtx context.Context) <-chan struct{}
}
type VolumeChooser ¶
type VolumeChooser interface {
Choose(options ChooseVolumeOptions) (VolumeID, error)
Reset(ids []VolumeID)
Refresh(id VolumeID)
}
type VolumeHandle ¶
type VolumeHandle interface {
io.Closer
Info() VolumeInfo
GetChunkStorage() ChunkStorage
GetCharacteristicsProvider() VolumeCharacteristicsProvider
GetLabelSources() []VolumeLabelSource
GetStatusProvider() VolumeStatusProvider
GetStructuredLoggingFieldsProvider() VolumeStructuredLoggingFieldsProvider
GetOTelAttributeProvider() VolumeOTelAttributeProvider
GetIOKitIOBlockStorageDriverStatisticsProvider() VolumeStatisticsProvider[IOKitIOBlockStorageDriverStatistics]
GetLinuxBlockLayerStatisticsProvider() VolumeStatisticsProvider[LinuxBlockLayerStatistics]
GetSpaceUtilizationStatisticsProvider() VolumeStatisticsProvider[SpaceUtilizationStatistics]
}
type VolumeHealth ¶
type VolumeHealth int
const ( VolumeUnknown VolumeHealth = iota VolumeOK VolumeDegraded VolumeFailed )
func (VolumeHealth) IsPermanent ¶
func (h VolumeHealth) IsPermanent() bool
IsPermanent reports whether the volume health represents a terminal, non‑recoverable failure. A permanent state (Failed) means the volume cannot safely serve any I/O and requires manual intervention or rebuild.
func (VolumeHealth) IsTransient ¶
func (h VolumeHealth) IsTransient() bool
IsTransient reports whether the volume health represents a temporary, recoverable condition. A transient state (Degraded) indicates the volume can still serve reads but should avoid writes until it recovers.
func (VolumeHealth) ShedsReads ¶
func (h VolumeHealth) ShedsReads() bool
ShedsReads reports whether the volume should reject read operations. Only Failed volumes shed reads, because data is no longer reliably accessible in that state.
func (VolumeHealth) ShedsWrites ¶
func (h VolumeHealth) ShedsWrites() bool
ShedsWrites reports whether the volume should reject write operations due to its current health. Degraded volumes shed writes to avoid worsening the condition, and Failed volumes shed both reads and writes.
func (VolumeHealth) String ¶
func (h VolumeHealth) String() string
type VolumeIDCounter ¶
type VolumeInfo ¶
type VolumeLabelPublisher ¶
type VolumeLabelSource ¶
type VolumeSet ¶
type VolumeSet struct {
// contains filtered or unexported fields
}
func NewVolumeSet ¶
func NewVolumeSet() *VolumeSet
func (*VolumeSet) ContainsVolume ¶
func (*VolumeSet) MarshalBinary ¶
func (*VolumeSet) RemoveVolume ¶
func (*VolumeSet) UnmarshalBinary ¶
type VolumeStatus ¶
type VolumeStatus struct {
Health VolumeHealth
}
type VolumeStatusProvider ¶
type VolumeStatusProvider interface {
Get() VolumeStatus
}
type VolumeStructuredLoggingFieldsProvider ¶
type VolumeStructuredLoggingFieldsProvider interface {
Get() []any
}
type ZoningType ¶
type ZoningType string
ZoningType describes the write‑ordering and zone‑management behavior required by a storage device. Zoned devices divide media into zones with sequential‑write constraints; the zoning type indicates how much of this behavior is enforced by the device versus managed by the host. The zero value ("") indicates the zoning type could not be determined.
const ( // ZoningTypeUnknown indicates that the zoning behavior could not be detected. ZoningTypeUnknown ZoningType = "" // ZoningTypeDriveManaged indicates that the device implements zoned media // internally but presents a conventional block interface to the host. // This corresponds to drive‑managed SMR HDDs. ZoningTypeDriveManaged ZoningType = "drive-managed" // ZoningTypeHostAware indicates that the device exposes zones to the host // and can benefit from sequential writes, but still accepts random writes. // This applies to host‑aware SMR HDDs and host‑aware ZNS devices. ZoningTypeHostAware ZoningType = "host-aware" // ZoningTypeHostManaged indicates that the device requires the host to // issue writes sequentially within zones and to manage zone resets. // This applies to host‑managed SMR (HM‑SMR), SCSI ZBC, and NVMe ZNS // devices operating in host‑managed mode. ZoningTypeHostManaged ZoningType = "host-managed" )