gceGCEDriver

package
v1.13.5 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2024 License: Apache-2.0 Imports: 41 Imported by: 1

Documentation

Index

Constants

View Source
const (
	// MaxVolumeSizeInBytes is the maximum standard and ssd size of 64TB
	MaxVolumeSizeInBytes     int64 = 64 * 1024 * 1024 * 1024 * 1024
	MinimumVolumeSizeInBytes int64 = 1 * 1024 * 1024 * 1024
	MinimumDiskSizeInGb            = 1
)

Variables

View Source
var ProbeCSIFullMethod = "/csi.v1.Identity/Probe"

Functions

func InitOtelTracing added in v1.13.0

func InitOtelTracing() (*otlptrace.Exporter, error)

Types

type GCEControllerServer

type GCEControllerServer struct {
	Driver        *GCEDriver
	CloudProvider gce.GCECompute
	Metrics       metrics.MetricsManager
	// contains filtered or unexported fields
}

func NewControllerServer

func NewControllerServer(gceDriver *GCEDriver, cloudProvider gce.GCECompute, errorBackoffInitialDuration, errorBackoffMaxDuration time.Duration, fallbackRequisiteZones []string, enableStoragePools bool, multiZoneVolumeHandleConfig MultiZoneVolumeHandleConfig) *GCEControllerServer

func (*GCEControllerServer) ControllerExpandVolume added in v0.4.0

func (*GCEControllerServer) ControllerGetCapabilities

ControllerGetCapabilities implements the default GRPC callout.

func (*GCEControllerServer) ControllerGetVolume added in v1.4.0

TODO(#809): Implement logic and advertise related capabilities.

func (*GCEControllerServer) ControllerPublishVolume

func (*GCEControllerServer) ControllerUnpublishVolume

func (*GCEControllerServer) CreateSnapshot

func (*GCEControllerServer) CreateVolume

func (*GCEControllerServer) DeleteSnapshot

func (*GCEControllerServer) DeleteVolume

func (*GCEControllerServer) GetCapacity

func (*GCEControllerServer) ListSnapshots

func (*GCEControllerServer) ListVolumes

func (*GCEControllerServer) ValidateVolumeCapabilities

type GCEDriver

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

func GetGCEDriver

func GetGCEDriver() *GCEDriver

func (*GCEDriver) AddControllerServiceCapabilities

func (gceDriver *GCEDriver) AddControllerServiceCapabilities(cl []csi.ControllerServiceCapability_RPC_Type) error

func (*GCEDriver) AddNodeServiceCapabilities

func (gceDriver *GCEDriver) AddNodeServiceCapabilities(nl []csi.NodeServiceCapability_RPC_Type) error

func (*GCEDriver) AddVolumeCapabilityAccessModes

func (gceDriver *GCEDriver) AddVolumeCapabilityAccessModes(vc []csi.VolumeCapability_AccessMode_Mode) error

func (*GCEDriver) Run

func (gceDriver *GCEDriver) Run(endpoint string, grpcLogCharCap int, enableOtelTracing bool)

func (*GCEDriver) SetupGCEDriver

func (gceDriver *GCEDriver) SetupGCEDriver(name, vendorVersion string, extraVolumeLabels map[string]string, identityServer *GCEIdentityServer, controllerServer *GCEControllerServer, nodeServer *GCENodeServer) error

func (*GCEDriver) ValidateControllerServiceRequest

func (gceDriver *GCEDriver) ValidateControllerServiceRequest(c csi.ControllerServiceCapability_RPC_Type) error

type GCEIdentityServer

type GCEIdentityServer struct {
	Driver *GCEDriver
}

func NewIdentityServer

func NewIdentityServer(gceDriver *GCEDriver) *GCEIdentityServer

func (*GCEIdentityServer) GetPluginCapabilities

func (gceIdentity *GCEIdentityServer) GetPluginCapabilities(ctx context.Context, req *csi.GetPluginCapabilitiesRequest) (*csi.GetPluginCapabilitiesResponse, error)

func (*GCEIdentityServer) GetPluginInfo

func (gceIdentity *GCEIdentityServer) GetPluginInfo(ctx context.Context, req *csi.GetPluginInfoRequest) (*csi.GetPluginInfoResponse, error)

GetPluginInfo(context.Context, *GetPluginInfoRequest) (*GetPluginInfoResponse, error)

func (*GCEIdentityServer) Probe

func (gceIdentity *GCEIdentityServer) Probe(ctx context.Context, req *csi.ProbeRequest) (*csi.ProbeResponse, error)

type GCENodeServer

type GCENodeServer struct {
	Driver          *GCEDriver
	Mounter         *mount.SafeFormatAndMount
	DeviceUtils     deviceutils.DeviceUtils
	VolumeStatter   mountmanager.Statter
	MetadataService metadataservice.MetadataService
	// contains filtered or unexported fields
}

func NewNodeServer

func NewNodeServer(gceDriver *GCEDriver, mounter *mount.SafeFormatAndMount, deviceUtils deviceutils.DeviceUtils, meta metadataservice.MetadataService, statter mountmanager.Statter) *GCENodeServer

func (*GCENodeServer) GetVolumeLimits added in v0.5.0

func (ns *GCENodeServer) GetVolumeLimits() (int64, error)

func (*GCENodeServer) NodeExpandVolume added in v0.4.0

func (*GCENodeServer) NodeGetCapabilities

func (*GCENodeServer) NodeGetInfo

func (*GCENodeServer) NodeGetVolumeStats added in v0.3.0

func (*GCENodeServer) NodePublishVolume

func (*GCENodeServer) NodeStageVolume

func (*GCENodeServer) NodeUnpublishVolume

func (*GCENodeServer) NodeUnstageVolume

func (*GCENodeServer) WithSerializedFormatAndMount added in v1.9.9

func (ns *GCENodeServer) WithSerializedFormatAndMount(timeout time.Duration, maxConcurrent int) *GCENodeServer

type MultiZoneVolumeHandleConfig added in v1.13.1

type MultiZoneVolumeHandleConfig struct {
	// A set of supported disk types that are compatible with multi-zone volumeHandles.
	// The disk type is only validated on ControllerPublish.
	// Other operations that interacti with volumeHandle (ListVolumes/ControllerUnpublish)
	// don't validate the disk type. This ensures existing published multi-zone volumes
	// are listed and unpublished correctly. This allows this flag
	// to be ratcheted to be more restricted without affecting volumes that are already
	// published.
	DiskTypes []string

	// If set to true, the CSI driver will enable the multi-zone volumeHandle feature.
	// If set to false, volumeHandles that contain 'multi-zone' will not be translated
	// to their respective attachment zone (based on the node), which will result in
	// an "Unknown zone" error on ControllerPublish/ControllerUnpublish.
	Enable bool
}

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(enableOtelTracing bool) NonBlockingGRPCServer

type PDCSIContext added in v1.10.3

type PDCSIContext struct {
	ForceAttach bool
}

PDCSIContext is the extracted VolumeContext from controller requests.

Jump to

Keyboard shortcuts

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