Documentation ¶
Index ¶
- Variables
- type Cloud
- type ControllerSvc
- func (cs *ControllerSvc) ControllerExpandVolume(ctx context.Context, req *csi.ControllerExpandVolumeRequest) (*csi.ControllerExpandVolumeResponse, error)
- func (cs *ControllerSvc) ControllerGetCapabilities(_ context.Context, req *csi.ControllerGetCapabilitiesRequest) (*csi.ControllerGetCapabilitiesResponse, error)
- func (cs *ControllerSvc) ControllerGetVolume(_ context.Context, _ *csi.ControllerGetVolumeRequest) (*csi.ControllerGetVolumeResponse, error)
- func (cs *ControllerSvc) ControllerPublishVolume(ctx context.Context, req *csi.ControllerPublishVolumeRequest) (*csi.ControllerPublishVolumeResponse, error)
- func (cs *ControllerSvc) ControllerUnpublishVolume(ctx context.Context, req *csi.ControllerUnpublishVolumeRequest) (*csi.ControllerUnpublishVolumeResponse, error)
- func (cs *ControllerSvc) CreateSnapshot(ctx context.Context, req *csi.CreateSnapshotRequest) (*csi.CreateSnapshotResponse, error)
- func (cs *ControllerSvc) CreateVolume(ctx context.Context, req *csi.CreateVolumeRequest) (*csi.CreateVolumeResponse, error)
- func (cs *ControllerSvc) DeleteSnapshot(ctx context.Context, req *csi.DeleteSnapshotRequest) (*csi.DeleteSnapshotResponse, error)
- func (cs *ControllerSvc) DeleteVolume(ctx context.Context, req *csi.DeleteVolumeRequest) (*csi.DeleteVolumeResponse, error)
- func (cs *ControllerSvc) GetCapacity(_ context.Context, _ *csi.GetCapacityRequest) (*csi.GetCapacityResponse, error)
- func (cs *ControllerSvc) ListSnapshots(ctx context.Context, req *csi.ListSnapshotsRequest) (*csi.ListSnapshotsResponse, error)
- func (cs *ControllerSvc) ListVolumes(_ context.Context, _ *csi.ListVolumesRequest) (*csi.ListVolumesResponse, error)
- func (cs *ControllerSvc) ValidateVolumeCapabilities(ctx context.Context, req *csi.ValidateVolumeCapabilitiesRequest) (*csi.ValidateVolumeCapabilitiesResponse, error)
- type Driver
- type IdentitySvc
- func (ids *IdentitySvc) GetPluginCapabilities(ctx context.Context, req *csi.GetPluginCapabilitiesRequest) (*csi.GetPluginCapabilitiesResponse, error)
- func (ids *IdentitySvc) GetPluginInfo(_ context.Context, req *csi.GetPluginInfoRequest) (*csi.GetPluginInfoResponse, error)
- func (ids *IdentitySvc) Probe(ctx context.Context, req *csi.ProbeRequest) (*csi.ProbeResponse, error)
- type Mounter
- type NodeMounter
- type NodeSvc
- func (ns *NodeSvc) NodeExpandVolume(_ context.Context, req *csi.NodeExpandVolumeRequest) (*csi.NodeExpandVolumeResponse, error)
- func (ns *NodeSvc) NodeGetCapabilities(_ context.Context, _ *csi.NodeGetCapabilitiesRequest) (*csi.NodeGetCapabilitiesResponse, error)
- func (ns *NodeSvc) NodeGetInfo(_ context.Context, _ *csi.NodeGetInfoRequest) (*csi.NodeGetInfoResponse, error)
- func (ns *NodeSvc) NodeGetVolumeStats(_ context.Context, req *csi.NodeGetVolumeStatsRequest) (*csi.NodeGetVolumeStatsResponse, error)
- func (ns *NodeSvc) NodePublishVolume(_ context.Context, req *csi.NodePublishVolumeRequest) (*csi.NodePublishVolumeResponse, error)
- func (ns *NodeSvc) NodeStageVolume(_ context.Context, req *csi.NodeStageVolumeRequest) (*csi.NodeStageVolumeResponse, error)
- func (ns *NodeSvc) NodeUnpublishVolume(_ context.Context, req *csi.NodeUnpublishVolumeRequest) (*csi.NodeUnpublishVolumeResponse, error)
- func (ns *NodeSvc) NodeUnstageVolume(_ context.Context, req *csi.NodeUnstageVolumeRequest) (*csi.NodeUnstageVolumeResponse, error)
- type VolcEngin
- func (volc *VolcEngin) AttachVolume(ctx context.Context, nodeId, volId string) error
- func (volc *VolcEngin) CreateSnapshot(ctx context.Context, volumeID, snapshotName string) (snapshot *types.Snapshot, err error)
- func (volc *VolcEngin) CreateVolume(ctx context.Context, name, volumeType, zoneId, snapshotId string, ...) (id string, err error)
- func (volc *VolcEngin) DeleteSnapshot(ctx context.Context, snapshotID string) error
- func (volc *VolcEngin) DeleteVolume(ctx context.Context, id string) error
- func (volc *VolcEngin) DescribeInstanceTypes(ctx context.Context, typeName string) (*types.InstanceTypeForDescribeInstanceTypesOutput, error)
- func (volc *VolcEngin) DetachVolume(ctx context.Context, nodeId, volId string) error
- func (volc *VolcEngin) DevicePathByVolId(volId string) string
- func (volc *VolcEngin) ExtendVolume(ctx context.Context, id string, newSize int64) (err error)
- func (volc *VolcEngin) GetSnapshotByID(ctx context.Context, snapshotID string) (snapshot *types.Snapshot, err error)
- func (volc *VolcEngin) GetSnapshotByName(ctx context.Context, name string) (snapshot *types.Snapshot, err error)
- func (volc *VolcEngin) NodeById(ctx context.Context, id string) (*types.InstanceForDescribeInstancesOutput, error)
- func (volc *VolcEngin) Region() string
- func (volc *VolcEngin) Topology() map[string]string
- func (volc *VolcEngin) VolumeById(ctx context.Context, id string) (vol *types.Volume, err error)
- func (volc *VolcEngin) VolumeByName(ctx context.Context, name string) (vol *types.Volume, err error)
- func (volc *VolcEngin) WaitVolumeBeCreated(ctx context.Context, id string) error
- func (volc *VolcEngin) WaitVolumeBeExtended(ctx context.Context, id string, sizeBytes int64) error
- func (volc *VolcEngin) WaitVolumeBeStatus(ctx context.Context, id, status string) error
- func (volc *VolcEngin) Zone() string
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // BLOCKVOLUMEPREFIX block volume mount prefix BLOCKVOLUMEPREFIX = filepath.Join("/var/lib/kubelet", "/plugins/kubernetes.io/csi/volumeDevices/publish") )
Functions ¶
This section is empty.
Types ¶
type Cloud ¶
type Cloud interface { CreateVolume(ctx context.Context, name, volumeType, zoneId, snapshotId string, capacity int64) (id string, err error) ExtendVolume(ctx context.Context, id string, newSize int64) (err error) DeleteVolume(ctx context.Context, id string) error DevicePathByVolId(volId string) string AttachVolume(ctx context.Context, nodeId, volId string) error DetachVolume(ctx context.Context, nodeId, volId string) error NodeById(ctx context.Context, id string) (*types.InstanceForDescribeInstancesOutput, error) DescribeInstanceTypes(ctx context.Context, typeName string) (*types.InstanceTypeForDescribeInstanceTypesOutput, error) VolumeById(ctx context.Context, id string) (vol *types.Volume, err error) VolumeByName(ctx context.Context, name string) (vol *types.Volume, err error) CreateSnapshot(ctx context.Context, volumeID, snapshotName string) (snapshot *types.Snapshot, err error) DeleteSnapshot(ctx context.Context, snapshotID string) error GetSnapshotByName(ctx context.Context, name string) (snapshot *types.Snapshot, err error) GetSnapshotByID(ctx context.Context, snapshotID string) (snapshot *types.Snapshot, err error) Region() string Zone() string Topology() map[string]string }
type ControllerSvc ¶
type ControllerSvc struct {
// contains filtered or unexported fields
}
func NewControllerSvc ¶
func NewControllerSvc(driver *Driver, cloud Cloud) *ControllerSvc
func (*ControllerSvc) ControllerExpandVolume ¶
func (cs *ControllerSvc) ControllerExpandVolume(ctx context.Context, req *csi.ControllerExpandVolumeRequest) (*csi.ControllerExpandVolumeResponse, error)
func (*ControllerSvc) ControllerGetCapabilities ¶
func (cs *ControllerSvc) ControllerGetCapabilities(_ context.Context, req *csi.ControllerGetCapabilitiesRequest) (*csi.ControllerGetCapabilitiesResponse, error)
func (*ControllerSvc) ControllerGetVolume ¶
func (cs *ControllerSvc) ControllerGetVolume(_ context.Context, _ *csi.ControllerGetVolumeRequest) (*csi.ControllerGetVolumeResponse, error)
func (*ControllerSvc) ControllerPublishVolume ¶
func (cs *ControllerSvc) ControllerPublishVolume(ctx context.Context, req *csi.ControllerPublishVolumeRequest) (*csi.ControllerPublishVolumeResponse, error)
func (*ControllerSvc) ControllerUnpublishVolume ¶
func (cs *ControllerSvc) ControllerUnpublishVolume(ctx context.Context, req *csi.ControllerUnpublishVolumeRequest) (*csi.ControllerUnpublishVolumeResponse, error)
func (*ControllerSvc) CreateSnapshot ¶
func (cs *ControllerSvc) CreateSnapshot(ctx context.Context, req *csi.CreateSnapshotRequest) (*csi.CreateSnapshotResponse, error)
func (*ControllerSvc) CreateVolume ¶
func (cs *ControllerSvc) CreateVolume(ctx context.Context, req *csi.CreateVolumeRequest) (*csi.CreateVolumeResponse, error)
func (*ControllerSvc) DeleteSnapshot ¶
func (cs *ControllerSvc) DeleteSnapshot(ctx context.Context, req *csi.DeleteSnapshotRequest) (*csi.DeleteSnapshotResponse, error)
func (*ControllerSvc) DeleteVolume ¶
func (cs *ControllerSvc) DeleteVolume(ctx context.Context, req *csi.DeleteVolumeRequest) (*csi.DeleteVolumeResponse, error)
func (*ControllerSvc) GetCapacity ¶
func (cs *ControllerSvc) GetCapacity(_ context.Context, _ *csi.GetCapacityRequest) (*csi.GetCapacityResponse, error)
func (*ControllerSvc) ListSnapshots ¶
func (cs *ControllerSvc) ListSnapshots(ctx context.Context, req *csi.ListSnapshotsRequest) (*csi.ListSnapshotsResponse, error)
func (*ControllerSvc) ListVolumes ¶
func (cs *ControllerSvc) ListVolumes(_ context.Context, _ *csi.ListVolumesRequest) (*csi.ListVolumesResponse, error)
func (*ControllerSvc) ValidateVolumeCapabilities ¶
func (cs *ControllerSvc) ValidateVolumeCapabilities(ctx context.Context, req *csi.ValidateVolumeCapabilitiesRequest) (*csi.ValidateVolumeCapabilitiesResponse, error)
type Driver ¶
type IdentitySvc ¶
type IdentitySvc struct {
// contains filtered or unexported fields
}
func NewIdentitySvc ¶
func NewIdentitySvc(driver *Driver) *IdentitySvc
func (*IdentitySvc) GetPluginCapabilities ¶
func (ids *IdentitySvc) GetPluginCapabilities(ctx context.Context, req *csi.GetPluginCapabilitiesRequest) (*csi.GetPluginCapabilitiesResponse, error)
func (*IdentitySvc) GetPluginInfo ¶
func (ids *IdentitySvc) GetPluginInfo(_ context.Context, req *csi.GetPluginInfoRequest) (*csi.GetPluginInfoResponse, error)
func (*IdentitySvc) Probe ¶
func (ids *IdentitySvc) Probe(ctx context.Context, req *csi.ProbeRequest) (*csi.ProbeResponse, error)
type Mounter ¶
type Mounter interface { mount.Interface FormatAndMount(source string, target string, fstype string, options []string) error GetDeviceNameFromMount(mountPath string) (string, int, error) }
Mounter is the interface implemented by NodeMounter.
type NodeMounter ¶
type NodeMounter struct {
*mount.SafeFormatAndMount
}
NodeMounter implements Mounter. A superstruct of SafeFormatAndMount.
func (NodeMounter) GetDeviceNameFromMount ¶
func (m NodeMounter) GetDeviceNameFromMount(mountPath string) (string, int, error)
GetDeviceNameFromMount returns the volume ID for a mount path.
type NodeSvc ¶
type NodeSvc struct {
// contains filtered or unexported fields
}
func (*NodeSvc) NodeExpandVolume ¶
func (ns *NodeSvc) NodeExpandVolume(_ context.Context, req *csi.NodeExpandVolumeRequest) (*csi.NodeExpandVolumeResponse, error)
func (*NodeSvc) NodeGetCapabilities ¶
func (ns *NodeSvc) NodeGetCapabilities(_ context.Context, _ *csi.NodeGetCapabilitiesRequest) (*csi.NodeGetCapabilitiesResponse, error)
func (*NodeSvc) NodeGetInfo ¶
func (ns *NodeSvc) NodeGetInfo(_ context.Context, _ *csi.NodeGetInfoRequest) (*csi.NodeGetInfoResponse, error)
func (*NodeSvc) NodeGetVolumeStats ¶
func (ns *NodeSvc) NodeGetVolumeStats(_ context.Context, req *csi.NodeGetVolumeStatsRequest) (*csi.NodeGetVolumeStatsResponse, error)
func (*NodeSvc) NodePublishVolume ¶
func (ns *NodeSvc) NodePublishVolume(_ context.Context, req *csi.NodePublishVolumeRequest) (*csi.NodePublishVolumeResponse, error)
func (*NodeSvc) NodeStageVolume ¶
func (ns *NodeSvc) NodeStageVolume(_ context.Context, req *csi.NodeStageVolumeRequest) (*csi.NodeStageVolumeResponse, error)
func (*NodeSvc) NodeUnpublishVolume ¶
func (ns *NodeSvc) NodeUnpublishVolume(_ context.Context, req *csi.NodeUnpublishVolumeRequest) (*csi.NodeUnpublishVolumeResponse, error)
func (*NodeSvc) NodeUnstageVolume ¶
func (ns *NodeSvc) NodeUnstageVolume(_ context.Context, req *csi.NodeUnstageVolumeRequest) (*csi.NodeUnstageVolumeResponse, error)
type VolcEngin ¶
type VolcEngin struct {
// contains filtered or unexported fields
}
func NewVolcEngin ¶
func NewVolcEngin(svcClients *sts.ServiceClients, region, zone string) *VolcEngin
func (*VolcEngin) AttachVolume ¶
func (*VolcEngin) CreateSnapshot ¶
func (*VolcEngin) CreateVolume ¶
func (*VolcEngin) DeleteSnapshot ¶
func (*VolcEngin) DeleteVolume ¶
func (*VolcEngin) DescribeInstanceTypes ¶
func (*VolcEngin) DetachVolume ¶
func (*VolcEngin) DevicePathByVolId ¶
func (*VolcEngin) ExtendVolume ¶
func (*VolcEngin) GetSnapshotByID ¶
func (*VolcEngin) GetSnapshotByName ¶
func (*VolcEngin) VolumeById ¶
func (*VolcEngin) VolumeByName ¶
func (*VolcEngin) WaitVolumeBeCreated ¶
func (*VolcEngin) WaitVolumeBeExtended ¶
func (*VolcEngin) WaitVolumeBeStatus ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.