Documentation ¶
Index ¶
- Constants
- func CloneVolume(...) error
- func CreateSnapshot(confFile, poolName, volumeName, snapshotName string) error
- func CreateVolume(confFile, volumeName string, size int64, parameters map[string]string) error
- func DeleteSnapshot(confFile, poolName, volumeName, snapshotName string) error
- func DeleteVolume(confFile, poolName, volumeName string) error
- func DetachCloneRelationship(...) error
- func ResizeVolume(confFile, poolName, volumeName string, size int64) error
- type CloneInfo
- type CloneRelation
- type CloneVolumeRequest
- type CloneVolumeResponse
- type CreateSnapshotRequest
- type CreateSnapshotResponse
- type CreateVolumeRequest
- type CreateVolumeResponse
- type DeleteSnapshotRequest
- type DeleteSnapshotResponse
- type DeleteVolumeRequest
- type DeleteVolumeResponse
- type DetachCloneRelationshipRequest
- type DetachCloneRelationshipResponse
- type GetVolumeForCloneRequest
- type GetVolumeForCloneResponse
- type ListCloneRequest
- type ListCloneRequest220
- type ListCloneResponse
- type ListSnapshotRequest
- type ListSnapshotResponse
- type ListVolumeRequest
- type ListVolumeResponse
- type ResizeVolumeRequest
- type ResizeVolumeResponse
- type Response
- type ResponseHeader
- type SnapshotInfo
- type Volume
- type VolumeForClone
Constants ¶
View Source
const (
RetCodeOK = 0
)
Variables ¶
This section is empty.
Functions ¶
func CloneVolume ¶ added in v1.2.0
func CreateSnapshot ¶ added in v1.2.0
func CreateVolume ¶
func DeleteSnapshot ¶ added in v1.2.0
func DeleteVolume ¶
func DetachCloneRelationship ¶ added in v1.2.0
func ResizeVolume ¶
Types ¶
type CloneInfo ¶ added in v1.2.0
type CloneInfo struct { Id int `json:"id"` SourceVol string `json:"source_vol"` TargetVol string `json:"target_vol"` CreateTime time.Time `json:"create_time" format:"ISO 8601"` Status string `json:"status"` StatusTime time.Time `json:"status_time" format:"ISO 8601"` }
func ListClone220 ¶ added in v1.2.0
type CloneRelation ¶ added in v1.2.0
type CloneVolumeRequest ¶ added in v1.2.0
type CloneVolumeResponse ¶ added in v1.2.0
type CloneVolumeResponse struct { ResponseHeader Id string `json:"id"` QueueName string `json:"queue_name"` }
type CreateSnapshotRequest ¶ added in v1.2.0
type CreateSnapshotResponse ¶ added in v1.2.0
type CreateSnapshotResponse struct {
ResponseHeader
}
type CreateVolumeRequest ¶
type CreateVolumeResponse ¶
type CreateVolumeResponse struct { ResponseHeader Id int `json:"id"` Size int `json:"size"` }
type DeleteSnapshotRequest ¶ added in v1.2.0
type DeleteSnapshotResponse ¶ added in v1.2.0
type DeleteSnapshotResponse struct { ResponseHeader Id int `json:"id"` }
type DeleteVolumeRequest ¶
type DeleteVolumeResponse ¶
type DeleteVolumeResponse struct { ResponseHeader Id int `json:"id"` }
type DetachCloneRelationshipRequest ¶ added in v1.2.0
type DetachCloneRelationshipResponse ¶ added in v1.2.0
type DetachCloneRelationshipResponse struct { ResponseHeader CloneRelations []CloneRelation `json:"CloneRelations"` }
type GetVolumeForCloneRequest ¶ added in v1.2.0
type GetVolumeForCloneResponse ¶ added in v1.2.0
type GetVolumeForCloneResponse struct { ResponseHeader VolumeInfo VolumeForClone `json:"VolumeInfo"` }
type ListCloneRequest ¶ added in v1.2.0
type ListCloneRequest220 ¶ added in v1.2.0
type ListCloneResponse ¶ added in v1.2.0
type ListCloneResponse struct { ResponseHeader CloneVolumes []CloneInfo `json:"CloneVolumes"` }
type ListSnapshotRequest ¶ added in v1.2.0
type ListSnapshotResponse ¶ added in v1.2.0
type ListSnapshotResponse struct { ResponseHeader VolumeId int `json:"volume_id"` SnapshotCount int `json:"snapshot_count"` Snapshots []SnapshotInfo `json:"snapshots"` }
type ListVolumeRequest ¶
type ListVolumeResponse ¶
type ListVolumeResponse struct { ResponseHeader Count int `json:"count"` Volumes []Volume `json:"volumes"` }
type ResizeVolumeRequest ¶
type ResizeVolumeResponse ¶
type ResizeVolumeResponse struct { ResponseHeader Id int `json:"id"` Size int `json:"size"` }
type Response ¶
type Response interface {
Header() *ResponseHeader
}
type ResponseHeader ¶
type ResponseHeader struct { Op string `json:"op"` RetCode int `json:"ret_code"` Reason string `json:"reason"` }
func (*ResponseHeader) Header ¶
func (r *ResponseHeader) Header() *ResponseHeader
type SnapshotInfo ¶ added in v1.2.0
type SnapshotInfo struct { SnapshotId int `json:"snapshot_id"` SnapshotName string `json:"snapshot_name"` SnapshotSize int64 `json:"snapshot_size"` Status string `json:"status"` CreateTime time.Time `json:"create_time" format:"ISO 8601"` }
func ListSnapshot ¶ added in v1.2.0
func ListSnapshot(confFile, poolName, volumeName, snapshotName string) (*SnapshotInfo, error)
type Volume ¶
type Volume struct { Id int `json:"id"` Name string `json:"name"` PoolName string `json:"pool_name"` Size int `json:"size"` ReplicationCount int `json:"replication_count"` Status string `json:"status"` MinReplicationCount int `json:"min_replication_count"` Role string `json:"role"` Policy string `json:"policy"` CreateTime time.Time `json:"create_time" format:"ISO 8601"` StatusTime time.Time `json:"status_time" format:"ISO 8601"` MetroReplica string `json:"metro_replica"` ProvisionType string `json:"provision_type"` // thin or thick MaxBs int `json:"max_bs"` VolumeAllocated int `json:"volume_allocated"` RgName string `json:"rg_name"` Encrypted string `json:"encrypted"` }
func ListVolume ¶
type VolumeForClone ¶ added in v1.2.0
type VolumeForClone struct { ID int `json:"id"` Size int `json:"size"` ReplicationCount int `json:"replication_count"` MinReplicationCount int `json:"min_replication_count"` Role string `json:"role"` MaxBs int `json:"max_bs"` Encrypte string `json:"encrypte"` KeyName string `json:"key_name"` Rg string `json:"rg"` }
func GetVolumeForClone ¶ added in v1.2.0
func GetVolumeForClone(confFile, poolName, volumeName string) (*VolumeForClone, error)
Click to show internal directories.
Click to hide internal directories.