csicommon

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 26, 2018 License: Apache-2.0 Imports: 11 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewControllerServiceCapability

func NewControllerServiceCapability(cap csi.ControllerServiceCapability_RPC_Type) *csi.ControllerServiceCapability

func NewVolumeCapabilityAccessMode

func NewVolumeCapabilityAccessMode(mode csi.VolumeCapability_AccessMode_Mode) *csi.VolumeCapability_AccessMode

func ParseEndpoint

func ParseEndpoint(ep string) (string, string, error)

func RunControllerPublishServer

func RunControllerPublishServer(endpoint string, d *CSIDriver, cs csi.ControllerServer)

func RunControllerandNodePublishServer

func RunControllerandNodePublishServer(endpoint string, d *CSIDriver, cs csi.ControllerServer, ns csi.NodeServer)

func RunNodePublishServer

func RunNodePublishServer(endpoint string, d *CSIDriver, ns csi.NodeServer)

Types

type CSIDriver

type CSIDriver struct {
	// contains filtered or unexported fields
}

func NewCSIDriver

func NewCSIDriver(name string, v string, nodeID string) *CSIDriver

Creates a NewCSIDriver object. Assumes vendor version is equal to driver version & does not support optional driver plugin info manifest field. Refer to CSI spec for more details.

func (*CSIDriver) AddControllerServiceCapabilities

func (d *CSIDriver) AddControllerServiceCapabilities(cl []csi.ControllerServiceCapability_RPC_Type)

func (*CSIDriver) AddVolumeCapabilityAccessModes

func (d *CSIDriver) AddVolumeCapabilityAccessModes(vc []csi.VolumeCapability_AccessMode_Mode) []*csi.VolumeCapability_AccessMode

func (*CSIDriver) GetVolumeCapabilityAccessModes

func (d *CSIDriver) GetVolumeCapabilityAccessModes() []*csi.VolumeCapability_AccessMode

func (*CSIDriver) ValidateControllerServiceRequest

func (d *CSIDriver) ValidateControllerServiceRequest(c csi.ControllerServiceCapability_RPC_Type) error

type DefaultControllerServer

type DefaultControllerServer struct {
	Driver *CSIDriver
}

func NewDefaultControllerServer

func NewDefaultControllerServer(d *CSIDriver) *DefaultControllerServer

func (*DefaultControllerServer) ControllerGetCapabilities

func (cs *DefaultControllerServer) ControllerGetCapabilities(ctx context.Context, req *csi.ControllerGetCapabilitiesRequest) (*csi.ControllerGetCapabilitiesResponse, error)

ControllerGetCapabilities implements the default GRPC callout. Default supports all capabilities

func (*DefaultControllerServer) ControllerPublishVolume

func (cs *DefaultControllerServer) ControllerPublishVolume(ctx context.Context, req *csi.ControllerPublishVolumeRequest) (*csi.ControllerPublishVolumeResponse, error)

func (*DefaultControllerServer) ControllerUnpublishVolume

func (cs *DefaultControllerServer) ControllerUnpublishVolume(ctx context.Context, req *csi.ControllerUnpublishVolumeRequest) (*csi.ControllerUnpublishVolumeResponse, error)

func (*DefaultControllerServer) CreateSnapshot

func (cs *DefaultControllerServer) CreateSnapshot(ctx context.Context, req *csi.CreateSnapshotRequest) (*csi.CreateSnapshotResponse, error)

func (*DefaultControllerServer) CreateVolume

func (cs *DefaultControllerServer) CreateVolume(ctx context.Context, req *csi.CreateVolumeRequest) (*csi.CreateVolumeResponse, error)

func (*DefaultControllerServer) DeleteSnapshot

func (cs *DefaultControllerServer) DeleteSnapshot(ctx context.Context, req *csi.DeleteSnapshotRequest) (*csi.DeleteSnapshotResponse, error)

func (*DefaultControllerServer) DeleteVolume

func (cs *DefaultControllerServer) DeleteVolume(ctx context.Context, req *csi.DeleteVolumeRequest) (*csi.DeleteVolumeResponse, error)

func (*DefaultControllerServer) GetCapacity

func (cs *DefaultControllerServer) GetCapacity(ctx context.Context, req *csi.GetCapacityRequest) (*csi.GetCapacityResponse, error)

func (*DefaultControllerServer) ListSnapshots

func (cs *DefaultControllerServer) ListSnapshots(ctx context.Context, req *csi.ListSnapshotsRequest) (*csi.ListSnapshotsResponse, error)

func (*DefaultControllerServer) ListVolumes

func (cs *DefaultControllerServer) ListVolumes(ctx context.Context, req *csi.ListVolumesRequest) (*csi.ListVolumesResponse, error)

func (*DefaultControllerServer) ValidateVolumeCapabilities

func (cs *DefaultControllerServer) ValidateVolumeCapabilities(ctx context.Context, req *csi.ValidateVolumeCapabilitiesRequest) (*csi.ValidateVolumeCapabilitiesResponse, error)

type DefaultIdentityServer

type DefaultIdentityServer struct {
	Driver *CSIDriver
}

func NewDefaultIdentityServer

func NewDefaultIdentityServer(d *CSIDriver) *DefaultIdentityServer

func (*DefaultIdentityServer) GetPluginCapabilities

func (ids *DefaultIdentityServer) GetPluginCapabilities(ctx context.Context, req *csi.GetPluginCapabilitiesRequest) (*csi.GetPluginCapabilitiesResponse, error)

func (*DefaultIdentityServer) GetPluginInfo

func (ids *DefaultIdentityServer) GetPluginInfo(ctx context.Context, req *csi.GetPluginInfoRequest) (*csi.GetPluginInfoResponse, error)

func (*DefaultIdentityServer) Probe

func (ids *DefaultIdentityServer) Probe(ctx context.Context, req *csi.ProbeRequest) (*csi.ProbeResponse, error)

type DefaultNodeServer

type DefaultNodeServer struct {
	Driver *CSIDriver
}

func NewDefaultNodeServer

func NewDefaultNodeServer(d *CSIDriver) *DefaultNodeServer

func (*DefaultNodeServer) NodeGetCapabilities

func (ns *DefaultNodeServer) NodeGetCapabilities(ctx context.Context, req *csi.NodeGetCapabilitiesRequest) (*csi.NodeGetCapabilitiesResponse, error)

func (*DefaultNodeServer) NodeGetId

func (ns *DefaultNodeServer) NodeGetId(ctx context.Context, req *csi.NodeGetIdRequest) (*csi.NodeGetIdResponse, error)

func (*DefaultNodeServer) NodeGetInfo

func (ns *DefaultNodeServer) NodeGetInfo(ctx context.Context, req *csi.NodeGetInfoRequest) (*csi.NodeGetInfoResponse, error)

func (*DefaultNodeServer) NodePublishVolume

func (ns *DefaultNodeServer) NodePublishVolume(ctx context.Context, req *csi.NodePublishVolumeRequest) (*csi.NodePublishVolumeResponse, error)

func (*DefaultNodeServer) NodeUnpublishVolume

func (ns *DefaultNodeServer) NodeUnpublishVolume(ctx context.Context, req *csi.NodeUnpublishVolumeRequest) (*csi.NodeUnpublishVolumeResponse, error)

type NonBlockingGRPCServer

type NonBlockingGRPCServer interface {
	// Start services at the endpoint
	Start(endpoint string, ids csi.IdentityServer, cs csi.ControllerServer, ns csi.NodeServer)
	// Waits for the service to stop
	Wait()
	// Stops the service gracefully
	Stop()
	// Stops the service forcefully
	ForceStop()
}

Defines Non blocking GRPC server interfaces

func NewNonBlockingGRPCServer

func NewNonBlockingGRPCServer() NonBlockingGRPCServer

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL