v1

package
v0.34.1 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2025 License: Apache-2.0 Imports: 9 Imported by: 67

Documentation

Index

Constants

View Source
const (
	PodResourcesLister_List_FullMethodName                    = "/v1.PodResourcesLister/List"
	PodResourcesLister_GetAllocatableResources_FullMethodName = "/v1.PodResourcesLister/GetAllocatableResources"
	PodResourcesLister_Get_FullMethodName                     = "/v1.PodResourcesLister/Get"
)

Variables

View Source
var File_staging_src_k8s_io_kubelet_pkg_apis_podresources_v1_api_proto protoreflect.FileDescriptor
View Source
var PodResourcesLister_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "v1.PodResourcesLister",
	HandlerType: (*PodResourcesListerServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "List",
			Handler:    _PodResourcesLister_List_Handler,
		},
		{
			MethodName: "GetAllocatableResources",
			Handler:    _PodResourcesLister_GetAllocatableResources_Handler,
		},
		{
			MethodName: "Get",
			Handler:    _PodResourcesLister_Get_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "staging/src/k8s.io/kubelet/pkg/apis/podresources/v1/api.proto",
}

PodResourcesLister_ServiceDesc is the grpc.ServiceDesc for PodResourcesLister service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterPodResourcesListerServer

func RegisterPodResourcesListerServer(s grpc.ServiceRegistrar, srv PodResourcesListerServer)

Types

type AllocatableResourcesRequest added in v0.21.0

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

func (*AllocatableResourcesRequest) Descriptor deprecated added in v0.21.0

func (*AllocatableResourcesRequest) Descriptor() ([]byte, []int)

Deprecated: Use AllocatableResourcesRequest.ProtoReflect.Descriptor instead.

func (*AllocatableResourcesRequest) ProtoMessage added in v0.21.0

func (*AllocatableResourcesRequest) ProtoMessage()

func (*AllocatableResourcesRequest) ProtoReflect added in v0.34.0

func (*AllocatableResourcesRequest) Reset added in v0.21.0

func (x *AllocatableResourcesRequest) Reset()

func (*AllocatableResourcesRequest) String added in v0.21.0

func (x *AllocatableResourcesRequest) String() string

type AllocatableResourcesResponse added in v0.21.0

type AllocatableResourcesResponse struct {
	Devices []*ContainerDevices `protobuf:"bytes,1,rep,name=devices,proto3" json:"devices,omitempty"`
	CpuIds  []int64             `protobuf:"varint,2,rep,packed,name=cpu_ids,json=cpuIds,proto3" json:"cpu_ids,omitempty"`
	Memory  []*ContainerMemory  `protobuf:"bytes,3,rep,name=memory,proto3" json:"memory,omitempty"`
	// contains filtered or unexported fields
}

AllocatableResourcesResponses contains informations about all the devices known by the kubelet

func (*AllocatableResourcesResponse) Descriptor deprecated added in v0.21.0

func (*AllocatableResourcesResponse) Descriptor() ([]byte, []int)

Deprecated: Use AllocatableResourcesResponse.ProtoReflect.Descriptor instead.

func (*AllocatableResourcesResponse) GetCpuIds added in v0.21.0

func (x *AllocatableResourcesResponse) GetCpuIds() []int64

func (*AllocatableResourcesResponse) GetDevices added in v0.21.0

func (*AllocatableResourcesResponse) GetMemory added in v0.22.0

func (*AllocatableResourcesResponse) ProtoMessage added in v0.21.0

func (*AllocatableResourcesResponse) ProtoMessage()

func (*AllocatableResourcesResponse) ProtoReflect added in v0.34.0

func (*AllocatableResourcesResponse) Reset added in v0.21.0

func (x *AllocatableResourcesResponse) Reset()

func (*AllocatableResourcesResponse) String added in v0.21.0

type CDIDevice added in v0.27.0

type CDIDevice struct {

	// Fully qualified CDI device name
	// for example: vendor.com/gpu=gpudevice1
	// see more details in the CDI specification:
	// https://github.com/container-orchestrated-devices/container-device-interface/blob/main/SPEC.md
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

CDIDevice specifies a CDI device information

func (*CDIDevice) Descriptor deprecated added in v0.27.0

func (*CDIDevice) Descriptor() ([]byte, []int)

Deprecated: Use CDIDevice.ProtoReflect.Descriptor instead.

func (*CDIDevice) GetName added in v0.27.0

func (x *CDIDevice) GetName() string

func (*CDIDevice) ProtoMessage added in v0.27.0

func (*CDIDevice) ProtoMessage()

func (*CDIDevice) ProtoReflect added in v0.34.0

func (x *CDIDevice) ProtoReflect() protoreflect.Message

func (*CDIDevice) Reset added in v0.27.0

func (x *CDIDevice) Reset()

func (*CDIDevice) String added in v0.27.0

func (x *CDIDevice) String() string

type ClaimResource added in v0.27.0

type ClaimResource struct {
	CdiDevices []*CDIDevice `protobuf:"bytes,1,rep,name=cdi_devices,json=cdiDevices,proto3" json:"cdi_devices,omitempty"`
	DriverName string       `protobuf:"bytes,2,opt,name=driver_name,json=driverName,proto3" json:"driver_name,omitempty"`
	PoolName   string       `protobuf:"bytes,3,opt,name=pool_name,json=poolName,proto3" json:"pool_name,omitempty"`
	DeviceName string       `protobuf:"bytes,4,opt,name=device_name,json=deviceName,proto3" json:"device_name,omitempty"`
	// contains filtered or unexported fields
}

ClaimResource contains resource information. The driver name/pool name/device name triplet uniquely identifies the device. Should DRA get extended to other kinds of resources, then device_name will be empty and other fields will get added. Each device at the DRA API level may map to zero or more CDI devices.

func (*ClaimResource) Descriptor deprecated added in v0.27.0

func (*ClaimResource) Descriptor() ([]byte, []int)

Deprecated: Use ClaimResource.ProtoReflect.Descriptor instead.

func (*ClaimResource) GetCdiDevices added in v0.34.0

func (x *ClaimResource) GetCdiDevices() []*CDIDevice

func (*ClaimResource) GetDeviceName added in v0.31.0

func (x *ClaimResource) GetDeviceName() string

func (*ClaimResource) GetDriverName added in v0.31.0

func (x *ClaimResource) GetDriverName() string

func (*ClaimResource) GetPoolName added in v0.31.0

func (x *ClaimResource) GetPoolName() string

func (*ClaimResource) ProtoMessage added in v0.27.0

func (*ClaimResource) ProtoMessage()

func (*ClaimResource) ProtoReflect added in v0.34.0

func (x *ClaimResource) ProtoReflect() protoreflect.Message

func (*ClaimResource) Reset added in v0.27.0

func (x *ClaimResource) Reset()

func (*ClaimResource) String added in v0.27.0

func (x *ClaimResource) String() string

type ContainerDevices

type ContainerDevices struct {
	ResourceName string        `protobuf:"bytes,1,opt,name=resource_name,json=resourceName,proto3" json:"resource_name,omitempty"`
	DeviceIds    []string      `protobuf:"bytes,2,rep,name=device_ids,json=deviceIds,proto3" json:"device_ids,omitempty"`
	Topology     *TopologyInfo `protobuf:"bytes,3,opt,name=topology,proto3" json:"topology,omitempty"`
	// contains filtered or unexported fields
}

ContainerDevices contains information about the devices assigned to a container

func (*ContainerDevices) Descriptor deprecated

func (*ContainerDevices) Descriptor() ([]byte, []int)

Deprecated: Use ContainerDevices.ProtoReflect.Descriptor instead.

func (*ContainerDevices) GetDeviceIds

func (x *ContainerDevices) GetDeviceIds() []string

func (*ContainerDevices) GetResourceName

func (x *ContainerDevices) GetResourceName() string

func (*ContainerDevices) GetTopology

func (x *ContainerDevices) GetTopology() *TopologyInfo

func (*ContainerDevices) ProtoMessage

func (*ContainerDevices) ProtoMessage()

func (*ContainerDevices) ProtoReflect added in v0.34.0

func (x *ContainerDevices) ProtoReflect() protoreflect.Message

func (*ContainerDevices) Reset

func (x *ContainerDevices) Reset()

func (*ContainerDevices) String

func (x *ContainerDevices) String() string

type ContainerMemory added in v0.22.0

type ContainerMemory struct {
	MemoryType string        `protobuf:"bytes,1,opt,name=memory_type,json=memoryType,proto3" json:"memory_type,omitempty"`
	Size       uint64        `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"`
	Topology   *TopologyInfo `protobuf:"bytes,3,opt,name=topology,proto3" json:"topology,omitempty"`
	// contains filtered or unexported fields
}

ContainerMemory contains information about memory and hugepages assigned to a container

func (*ContainerMemory) Descriptor deprecated added in v0.22.0

func (*ContainerMemory) Descriptor() ([]byte, []int)

Deprecated: Use ContainerMemory.ProtoReflect.Descriptor instead.

func (*ContainerMemory) GetMemoryType added in v0.22.0

func (x *ContainerMemory) GetMemoryType() string

func (*ContainerMemory) GetSize added in v0.34.0

func (x *ContainerMemory) GetSize() uint64

func (*ContainerMemory) GetTopology added in v0.22.0

func (x *ContainerMemory) GetTopology() *TopologyInfo

func (*ContainerMemory) ProtoMessage added in v0.22.0

func (*ContainerMemory) ProtoMessage()

func (*ContainerMemory) ProtoReflect added in v0.34.0

func (x *ContainerMemory) ProtoReflect() protoreflect.Message

func (*ContainerMemory) Reset added in v0.22.0

func (x *ContainerMemory) Reset()

func (*ContainerMemory) String added in v0.22.0

func (x *ContainerMemory) String() string

type ContainerResources

type ContainerResources struct {
	Name             string              `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Devices          []*ContainerDevices `protobuf:"bytes,2,rep,name=devices,proto3" json:"devices,omitempty"`
	CpuIds           []int64             `protobuf:"varint,3,rep,packed,name=cpu_ids,json=cpuIds,proto3" json:"cpu_ids,omitempty"`
	Memory           []*ContainerMemory  `protobuf:"bytes,4,rep,name=memory,proto3" json:"memory,omitempty"`
	DynamicResources []*DynamicResource  `protobuf:"bytes,5,rep,name=dynamic_resources,json=dynamicResources,proto3" json:"dynamic_resources,omitempty"`
	// contains filtered or unexported fields
}

ContainerResources contains information about the resources assigned to a container

func (*ContainerResources) Descriptor deprecated

func (*ContainerResources) Descriptor() ([]byte, []int)

Deprecated: Use ContainerResources.ProtoReflect.Descriptor instead.

func (*ContainerResources) GetCpuIds

func (x *ContainerResources) GetCpuIds() []int64

func (*ContainerResources) GetDevices

func (x *ContainerResources) GetDevices() []*ContainerDevices

func (*ContainerResources) GetDynamicResources added in v0.27.0

func (x *ContainerResources) GetDynamicResources() []*DynamicResource

func (*ContainerResources) GetMemory added in v0.22.0

func (x *ContainerResources) GetMemory() []*ContainerMemory

func (*ContainerResources) GetName

func (x *ContainerResources) GetName() string

func (*ContainerResources) ProtoMessage

func (*ContainerResources) ProtoMessage()

func (*ContainerResources) ProtoReflect added in v0.34.0

func (x *ContainerResources) ProtoReflect() protoreflect.Message

func (*ContainerResources) Reset

func (x *ContainerResources) Reset()

func (*ContainerResources) String

func (x *ContainerResources) String() string

type DynamicResource added in v0.27.0

type DynamicResource struct {

	// tombstone: removed in 1.31 because claims are no longer associated with one class
	// string class_name = 1;
	ClaimName      string           `protobuf:"bytes,2,opt,name=claim_name,json=claimName,proto3" json:"claim_name,omitempty"`
	ClaimNamespace string           `protobuf:"bytes,3,opt,name=claim_namespace,json=claimNamespace,proto3" json:"claim_namespace,omitempty"`
	ClaimResources []*ClaimResource `protobuf:"bytes,4,rep,name=claim_resources,json=claimResources,proto3" json:"claim_resources,omitempty"`
	// contains filtered or unexported fields
}

DynamicResource contains information about the devices assigned to a container by DRA

func (*DynamicResource) Descriptor deprecated added in v0.27.0

func (*DynamicResource) Descriptor() ([]byte, []int)

Deprecated: Use DynamicResource.ProtoReflect.Descriptor instead.

func (*DynamicResource) GetClaimName added in v0.27.0

func (x *DynamicResource) GetClaimName() string

func (*DynamicResource) GetClaimNamespace added in v0.27.0

func (x *DynamicResource) GetClaimNamespace() string

func (*DynamicResource) GetClaimResources added in v0.27.0

func (x *DynamicResource) GetClaimResources() []*ClaimResource

func (*DynamicResource) ProtoMessage added in v0.27.0

func (*DynamicResource) ProtoMessage()

func (*DynamicResource) ProtoReflect added in v0.34.0

func (x *DynamicResource) ProtoReflect() protoreflect.Message

func (*DynamicResource) Reset added in v0.27.0

func (x *DynamicResource) Reset()

func (*DynamicResource) String added in v0.27.0

func (x *DynamicResource) String() string

type GetPodResourcesRequest added in v0.27.0

type GetPodResourcesRequest struct {
	PodName      string `protobuf:"bytes,1,opt,name=pod_name,json=podName,proto3" json:"pod_name,omitempty"`
	PodNamespace string `protobuf:"bytes,2,opt,name=pod_namespace,json=podNamespace,proto3" json:"pod_namespace,omitempty"`
	// contains filtered or unexported fields
}

GetPodResourcesRequest contains information about the pod

func (*GetPodResourcesRequest) Descriptor deprecated added in v0.27.0

func (*GetPodResourcesRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetPodResourcesRequest.ProtoReflect.Descriptor instead.

func (*GetPodResourcesRequest) GetPodName added in v0.27.0

func (x *GetPodResourcesRequest) GetPodName() string

func (*GetPodResourcesRequest) GetPodNamespace added in v0.27.0

func (x *GetPodResourcesRequest) GetPodNamespace() string

func (*GetPodResourcesRequest) ProtoMessage added in v0.27.0

func (*GetPodResourcesRequest) ProtoMessage()

func (*GetPodResourcesRequest) ProtoReflect added in v0.34.0

func (x *GetPodResourcesRequest) ProtoReflect() protoreflect.Message

func (*GetPodResourcesRequest) Reset added in v0.27.0

func (x *GetPodResourcesRequest) Reset()

func (*GetPodResourcesRequest) String added in v0.27.0

func (x *GetPodResourcesRequest) String() string

type GetPodResourcesResponse added in v0.27.0

type GetPodResourcesResponse struct {
	PodResources *PodResources `protobuf:"bytes,1,opt,name=pod_resources,json=podResources,proto3" json:"pod_resources,omitempty"`
	// contains filtered or unexported fields
}

GetPodResourcesResponse contains information about the pod the devices

func (*GetPodResourcesResponse) Descriptor deprecated added in v0.27.0

func (*GetPodResourcesResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetPodResourcesResponse.ProtoReflect.Descriptor instead.

func (*GetPodResourcesResponse) GetPodResources added in v0.27.0

func (x *GetPodResourcesResponse) GetPodResources() *PodResources

func (*GetPodResourcesResponse) ProtoMessage added in v0.27.0

func (*GetPodResourcesResponse) ProtoMessage()

func (*GetPodResourcesResponse) ProtoReflect added in v0.34.0

func (x *GetPodResourcesResponse) ProtoReflect() protoreflect.Message

func (*GetPodResourcesResponse) Reset added in v0.27.0

func (x *GetPodResourcesResponse) Reset()

func (*GetPodResourcesResponse) String added in v0.27.0

func (x *GetPodResourcesResponse) String() string

type ListPodResourcesRequest

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

ListPodResourcesRequest is the request made to the PodResourcesLister service

func (*ListPodResourcesRequest) Descriptor deprecated

func (*ListPodResourcesRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListPodResourcesRequest.ProtoReflect.Descriptor instead.

func (*ListPodResourcesRequest) ProtoMessage

func (*ListPodResourcesRequest) ProtoMessage()

func (*ListPodResourcesRequest) ProtoReflect added in v0.34.0

func (x *ListPodResourcesRequest) ProtoReflect() protoreflect.Message

func (*ListPodResourcesRequest) Reset

func (x *ListPodResourcesRequest) Reset()

func (*ListPodResourcesRequest) String

func (x *ListPodResourcesRequest) String() string

type ListPodResourcesResponse

type ListPodResourcesResponse struct {
	PodResources []*PodResources `protobuf:"bytes,1,rep,name=pod_resources,json=podResources,proto3" json:"pod_resources,omitempty"`
	// contains filtered or unexported fields
}

ListPodResourcesResponse is the response returned by List function

func (*ListPodResourcesResponse) Descriptor deprecated

func (*ListPodResourcesResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListPodResourcesResponse.ProtoReflect.Descriptor instead.

func (*ListPodResourcesResponse) GetPodResources

func (x *ListPodResourcesResponse) GetPodResources() []*PodResources

func (*ListPodResourcesResponse) ProtoMessage

func (*ListPodResourcesResponse) ProtoMessage()

func (*ListPodResourcesResponse) ProtoReflect added in v0.34.0

func (x *ListPodResourcesResponse) ProtoReflect() protoreflect.Message

func (*ListPodResourcesResponse) Reset

func (x *ListPodResourcesResponse) Reset()

func (*ListPodResourcesResponse) String

func (x *ListPodResourcesResponse) String() string

type NUMANode

type NUMANode struct {
	ID int64 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"`
	// contains filtered or unexported fields
}

NUMA representation of NUMA node

func (*NUMANode) Descriptor deprecated

func (*NUMANode) Descriptor() ([]byte, []int)

Deprecated: Use NUMANode.ProtoReflect.Descriptor instead.

func (*NUMANode) GetID

func (x *NUMANode) GetID() int64

func (*NUMANode) ProtoMessage

func (*NUMANode) ProtoMessage()

func (*NUMANode) ProtoReflect added in v0.34.0

func (x *NUMANode) ProtoReflect() protoreflect.Message

func (*NUMANode) Reset

func (x *NUMANode) Reset()

func (*NUMANode) String

func (x *NUMANode) String() string

type PodResources

type PodResources struct {
	Name       string                `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Namespace  string                `protobuf:"bytes,2,opt,name=namespace,proto3" json:"namespace,omitempty"`
	Containers []*ContainerResources `protobuf:"bytes,3,rep,name=containers,proto3" json:"containers,omitempty"`
	// contains filtered or unexported fields
}

PodResources contains information about the node resources assigned to a pod

func (*PodResources) Descriptor deprecated

func (*PodResources) Descriptor() ([]byte, []int)

Deprecated: Use PodResources.ProtoReflect.Descriptor instead.

func (*PodResources) GetContainers

func (x *PodResources) GetContainers() []*ContainerResources

func (*PodResources) GetName

func (x *PodResources) GetName() string

func (*PodResources) GetNamespace

func (x *PodResources) GetNamespace() string

func (*PodResources) ProtoMessage

func (*PodResources) ProtoMessage()

func (*PodResources) ProtoReflect added in v0.34.0

func (x *PodResources) ProtoReflect() protoreflect.Message

func (*PodResources) Reset

func (x *PodResources) Reset()

func (*PodResources) String

func (x *PodResources) String() string

type PodResourcesListerClient

type PodResourcesListerClient interface {
	List(ctx context.Context, in *ListPodResourcesRequest, opts ...grpc.CallOption) (*ListPodResourcesResponse, error)
	GetAllocatableResources(ctx context.Context, in *AllocatableResourcesRequest, opts ...grpc.CallOption) (*AllocatableResourcesResponse, error)
	Get(ctx context.Context, in *GetPodResourcesRequest, opts ...grpc.CallOption) (*GetPodResourcesResponse, error)
}

PodResourcesListerClient is the client API for PodResourcesLister service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

PodResourcesLister is a service provided by the kubelet that provides information about the node resources consumed by pods and containers on the node

type PodResourcesListerServer

type PodResourcesListerServer interface {
	List(context.Context, *ListPodResourcesRequest) (*ListPodResourcesResponse, error)
	GetAllocatableResources(context.Context, *AllocatableResourcesRequest) (*AllocatableResourcesResponse, error)
	Get(context.Context, *GetPodResourcesRequest) (*GetPodResourcesResponse, error)
	// contains filtered or unexported methods
}

PodResourcesListerServer is the server API for PodResourcesLister service. All implementations must embed UnimplementedPodResourcesListerServer for forward compatibility.

PodResourcesLister is a service provided by the kubelet that provides information about the node resources consumed by pods and containers on the node

type TopologyInfo

type TopologyInfo struct {
	Nodes []*NUMANode `protobuf:"bytes,1,rep,name=nodes,proto3" json:"nodes,omitempty"`
	// contains filtered or unexported fields
}

Topology describes hardware topology of the resource

func (*TopologyInfo) Descriptor deprecated

func (*TopologyInfo) Descriptor() ([]byte, []int)

Deprecated: Use TopologyInfo.ProtoReflect.Descriptor instead.

func (*TopologyInfo) GetNodes

func (x *TopologyInfo) GetNodes() []*NUMANode

func (*TopologyInfo) ProtoMessage

func (*TopologyInfo) ProtoMessage()

func (*TopologyInfo) ProtoReflect added in v0.34.0

func (x *TopologyInfo) ProtoReflect() protoreflect.Message

func (*TopologyInfo) Reset

func (x *TopologyInfo) Reset()

func (*TopologyInfo) String

func (x *TopologyInfo) String() string

type UnimplementedPodResourcesListerServer

type UnimplementedPodResourcesListerServer struct{}

UnimplementedPodResourcesListerServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedPodResourcesListerServer) Get added in v0.27.0

func (UnimplementedPodResourcesListerServer) GetAllocatableResources added in v0.21.0

func (UnimplementedPodResourcesListerServer) List

type UnsafePodResourcesListerServer added in v0.34.0

type UnsafePodResourcesListerServer interface {
	// contains filtered or unexported methods
}

UnsafePodResourcesListerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PodResourcesListerServer will result in compilation errors.

Jump to

Keyboard shortcuts

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