mirror of
https://github.com/gluster/glusterd2.git
synced 2026-02-05 12:45:38 +01:00
Except Bricks list(Currently shows as NODEID:BRICKPATH), all other fields output matches with existing Gluster CLI output Signed-off-by: Aravinda VK <avishwan@redhat.com>
36 lines
740 B
Go
36 lines
740 B
Go
package api
|
|
|
|
// VolType is the type of volume.
|
|
//go:generate jsonenums -type=VolType
|
|
type VolType uint16
|
|
|
|
const (
|
|
// Distribute is a plain distribute volume
|
|
Distribute VolType = iota
|
|
// Replicate is plain replicate volume
|
|
Replicate
|
|
// Disperse is a plain erasure coded volume
|
|
Disperse
|
|
// DistReplicate is a distribute-replicate volume
|
|
DistReplicate
|
|
// DistDisperse is a distribute-'erasure coded' volume
|
|
DistDisperse
|
|
)
|
|
|
|
func (t VolType) String() string {
|
|
switch t {
|
|
case Distribute:
|
|
return "Distribute"
|
|
case Replicate:
|
|
return "Replicate"
|
|
case Disperse:
|
|
return "Disperse"
|
|
case DistReplicate:
|
|
return "Distributed-Replicate"
|
|
case DistDisperse:
|
|
return "Distributed-Disperse"
|
|
default:
|
|
return "invalid VolState"
|
|
}
|
|
}
|