csi

package
v0.0.0-...-763f55e Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Default values for volume context
	CSI_STORAGE_PVC_NAME      string = "csi.storage.k8s.io/pvc/name"
	CSI_STORAGE_PVC_NAMESPACE string = "csi.storage.k8s.io/pvc/namespace"

	CSI_STORAGE_POD_NAME                        string = "csi.storage.k8s.io/pod.name"
	CSI_STORAGE_POD_NAMESPACE                   string = "csi.storage.k8s.io/pod.namespace"
	CSI_STORAGE_POD_UID                         string = "csi.storage.k8s.io/pod.uid"
	CSI_STORAGE_SERVICE_ACCOUNT_NAME            string = "csi.storage.k8s.io/serviceAccount.name"
	CSI_STORAGE_EPHEMERAL                       string = "csi.storage.k8s.io/ephemeral"
	STORAGE_KUBERNETES_CSI_PROVISIONER_IDENTITY string = "storage.kubernetes.io/csiProvisionerIdentity"
	VOLUME_KUBERNETES_STORAGE_PROVISIONER       string = "volume.kubernetes.io/storage-provisioner"
)
View Source
const (
	DefaultDriverName = "listeners.zncdata.dev"
)

Variables

This section is empty.

Functions

func CheckDynamicPV

func CheckDynamicPV(name string) (bool, error)

func GetLogLevel

func GetLogLevel(method string) int

func LogGRPC

func LogGRPC(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)

func ParseEndpoint

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

Types

type ControllerServer

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

func NewControllerServer

func NewControllerServer(client client.Client) *ControllerServer

func (*ControllerServer) ControllerExpandVolume

func (*ControllerServer) ControllerGetCapabilities

func (*ControllerServer) ControllerGetVolume

func (*ControllerServer) ControllerModifyVolume

func (*ControllerServer) ControllerPublishVolume

func (*ControllerServer) ControllerUnpublishVolume

func (*ControllerServer) CreateSnapshot

func (*ControllerServer) CreateVolume

func (*ControllerServer) DeleteSnapshot

func (*ControllerServer) DeleteVolume

func (*ControllerServer) GetCapacity

func (*ControllerServer) ListSnapshots

func (*ControllerServer) ListVolumes

func (*ControllerServer) ValidateVolumeCapabilities

type Driver

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

func NewDriver

func NewDriver(
	name string,
	nodeID string,
	endpoint string,
	client client.Client,
) *Driver

func (*Driver) Run

func (d *Driver) Run(ctx context.Context, testMode bool) error

func (*Driver) Stop

func (d *Driver) Stop()

type IdentityServer

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

func NewIdentityServer

func NewIdentityServer(name, version string) *IdentityServer

func (IdentityServer) GetPluginCapabilities

func (IdentityServer) GetPluginInfo

func (IdentityServer) Probe

func (i IdentityServer) Probe(ctx context.Context, request *csi.ProbeRequest) (*csi.ProbeResponse, error)

type NodeServer

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

func NewNodeServer

func NewNodeServer(
	nodeId string,
	mounter mount.Interface,
	client client.Client,
) *NodeServer

func (NodeServer) NodeExpandVolume

func (*NodeServer) NodeGetCapabilities

func (*NodeServer) NodeGetInfo

func (n *NodeServer) NodeGetInfo(ctx context.Context, request *csi.NodeGetInfoRequest) (*csi.NodeGetInfoResponse, error)

func (*NodeServer) NodeGetVolumeStats

func (*NodeServer) NodePublishVolume

func (n *NodeServer) NodePublishVolume(ctx context.Context, request *csi.NodePublishVolumeRequest) (*csi.NodePublishVolumeResponse, error)

func (*NodeServer) NodeStageVolume

func (n *NodeServer) NodeStageVolume(ctx context.Context, request *csi.NodeStageVolumeRequest) (*csi.NodeStageVolumeResponse, error)

func (*NodeServer) NodeUnpublishVolume

NodeUnpublishVolume unpublishes the volume from the node. unmount the volume from the target path, and remove the target path

func (*NodeServer) NodeUnstageVolume

func (n *NodeServer) NodeUnstageVolume(ctx context.Context, request *csi.NodeUnstageVolumeRequest) (*csi.NodeUnstageVolumeResponse, error)

type NonBlockingServer

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

NonBlockingServer Defines Non blocking GRPC server interfaces

func NewNonBlockingServer

func NewNonBlockingServer() NonBlockingServer

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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