Documentation ¶
Overview ¶
Package v1alpha1 is a generated protocol buffer package.
It is generated from these files:
k8s.io/kubernetes/vendor/k8s.io/api/resource/v1alpha1/generated.proto
It has these top-level messages:
Pool PoolList PoolSpec PoolStatus
Index ¶
- Constants
- Variables
- func Resource(resource string) schema.GroupResource
- type Pool
- func (in *Pool) DeepCopy() *Pool
- func (in *Pool) DeepCopyInto(out *Pool)
- func (in *Pool) DeepCopyObject() runtime.Object
- func (*Pool) Descriptor() ([]byte, []int)
- func (m *Pool) Marshal() (dAtA []byte, err error)
- func (m *Pool) MarshalTo(dAtA []byte) (int, error)
- func (*Pool) ProtoMessage()
- func (m *Pool) Reset()
- func (m *Pool) Size() (n int)
- func (this *Pool) String() string
- func (m *Pool) Unmarshal(dAtA []byte) error
- type PoolList
- func (in *PoolList) DeepCopy() *PoolList
- func (in *PoolList) DeepCopyInto(out *PoolList)
- func (in *PoolList) DeepCopyObject() runtime.Object
- func (*PoolList) Descriptor() ([]byte, []int)
- func (m *PoolList) Marshal() (dAtA []byte, err error)
- func (m *PoolList) MarshalTo(dAtA []byte) (int, error)
- func (*PoolList) ProtoMessage()
- func (m *PoolList) Reset()
- func (m *PoolList) Size() (n int)
- func (this *PoolList) String() string
- func (m *PoolList) Unmarshal(dAtA []byte) error
- type PoolSpec
- func (in *PoolSpec) DeepCopy() *PoolSpec
- func (in *PoolSpec) DeepCopyInto(out *PoolSpec)
- func (*PoolSpec) Descriptor() ([]byte, []int)
- func (m *PoolSpec) Marshal() (dAtA []byte, err error)
- func (m *PoolSpec) MarshalTo(dAtA []byte) (int, error)
- func (*PoolSpec) ProtoMessage()
- func (m *PoolSpec) Reset()
- func (m *PoolSpec) Size() (n int)
- func (this *PoolSpec) String() string
- func (m *PoolSpec) Unmarshal(dAtA []byte) error
- type PoolStatus
- func (in *PoolStatus) DeepCopy() *PoolStatus
- func (in *PoolStatus) DeepCopyInto(out *PoolStatus)
- func (*PoolStatus) Descriptor() ([]byte, []int)
- func (m *PoolStatus) Marshal() (dAtA []byte, err error)
- func (m *PoolStatus) MarshalTo(dAtA []byte) (int, error)
- func (*PoolStatus) ProtoMessage()
- func (m *PoolStatus) Reset()
- func (m *PoolStatus) Size() (n int)
- func (this *PoolStatus) String() string
- func (m *PoolStatus) Unmarshal(dAtA []byte) error
Constants ¶
const ( // GroupName is the group name used in this package. GroupName = "resource.aibee.cn" // GroupVersion is the version of scheduling group GroupVersion = "v1alpha1" )
const GroupNameAnnotationKey = "resource.aibee.cn/pool"
GroupNameAnnotationKey is the annotation key of Pod to identify which ResourcePool it belongs to.
Variables ¶
var ( ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") )
var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme )
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: GroupVersion}
SchemeGroupVersion is the group version used to register these objects.
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group-qualified GroupResource.
Types ¶
type Pool ¶
type Pool struct { metav1.TypeMeta `json:",inline"` // +optional metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the desired resources divided // +optional Spec PoolSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Status defines the actual enforced deserved resources and its current usage // +optional Status PoolStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` }
Pool
func (*Pool) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Pool.
func (*Pool) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Pool) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Pool) Descriptor ¶ added in v1.0.0
func (*Pool) ProtoMessage ¶ added in v1.0.0
func (*Pool) ProtoMessage()
type PoolList ¶
type PoolList struct { metav1.TypeMeta `json:",inline"` // Standard list metadata // +optional metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // items is the list of Pool Items []Pool `json:"items" protobuf:"bytes,2,rep,name=items"` }
Pool is a collection of resource pools.
func (*PoolList) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolList.
func (*PoolList) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PoolList) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*PoolList) Descriptor ¶ added in v1.0.0
func (*PoolList) ProtoMessage ¶ added in v1.0.0
func (*PoolList) ProtoMessage()
type PoolSpec ¶
type PoolSpec struct { // NodeSelector match node label // +optional NodeSelector *metav1.LabelSelector `json:"nodeSelector,omitempty" protobuf:"bytes,1,opt,name=nodeSelector"` // DisablePreemption flag whether task can preempt resources in the same pool , // if false, task in pool can preempt resources from other pools // if true, task cannot preempt resources from other pools and wait available // resource in self pool // +optional DisablePreemption bool `json:"disablePreemption,omitempty" protobuf:"varint,2,opt,name=disablePreemption"` // DisableBorrowing flag whether task in self pool can borrow resources from other pool, // if false, task can borrow resources from other pool // if true, task will only can use deserved resources // +optional DisableBorrowing bool `json:"disableBorrowing,omitempty" protobuf:"varint,3,opt,name=disableBorrowing"` // BorrowingPools only borrow from those pools, // only available when DisableBorrowing is false, // if empty can borrow all sharing pools // +optional BorrowingPools []string `json:"borrowingPools,omitempty" protobuf:"bytes,4,opt,name=borrowingPools"` // DisableSharing flag if self pool share its resource to other pool, // if false, the pool can be preempted by task in other pool // if true, the pool will not be preempted. // +optional DisableSharing bool `json:"disableSharing,omitempty" protobuf:"varint,5,opt,name=disableSharing"` }
PoolSpec
func (*PoolSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolSpec.
func (*PoolSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PoolSpec) Descriptor ¶ added in v1.0.0
func (*PoolSpec) ProtoMessage ¶ added in v1.0.0
func (*PoolSpec) ProtoMessage()
type PoolStatus ¶
type PoolStatus struct { // Capacity all resources of pool nodes capacity sum // +optional Capacity v1.ResourceList `json:"capacity,omitempty" protobuf:"bytes,1,opt,name=capacity,casttype=ResourceList,castkey=ResourceName"` // Allocatable all quota of pool divided // +optional Allocatable v1.ResourceList `json:"allocatable,omitempty" protobuf:"bytes,2,opt,name=allocatable,casttype=ResourceList,castkey=ResourceName"` // Requested is the current observed total usage of the resource by tasks in the Pool // Requested = (Deserved + System + Shared) // +optional Requests v1.ResourceList `json:"requests,omitempty" protobuf:"bytes,3,opt,name=requests,casttype=ResourceList,castkey=ResourceName"` Limits v1.ResourceList `json:"limits,omitempty" protobuf:"bytes,4,rep,name=limits,casttype=ResourceList,castkey=ResourceName"` // Deserved is the resource used by self pool task // +optional Deserved v1.ResourceList `json:"deserved,omitempty" protobuf:"bytes,5,opt,name=deserved,casttype=ResourceList,castkey=ResourceName"` // System is the resource used by scheduled by not ai-scheduler, i.e.calico, // +optional System v1.ResourceList `json:"system,omitempty" protobuf:"bytes,6,opt,name=system,casttype=ResourceList,castkey=ResourceName"` // +optional Shared v1.ResourceList `json:"shared,omitempty" protobuf:"bytes,7,opt,name=shared,casttype=ResourceList,castkey=ResourceName"` // Borrowed is the resources that task in self Pool borrows from other Pool // +optional Borrowed v1.ResourceList `json:"borrowed,omitempty" protobuf:"bytes,8,opt,name=borrowed,casttype=ResourceList,castkey=ResourceName"` // Free = (Allocatable - allocated) Free v1.ResourceList `json:"free,omitempty" protobuf:"bytes,9,opt,name=free,casttype=ResourceList,castkey=ResourceName"` }
PoolStatus
func (*PoolStatus) DeepCopy ¶
func (in *PoolStatus) DeepCopy() *PoolStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolStatus.
func (*PoolStatus) DeepCopyInto ¶
func (in *PoolStatus) DeepCopyInto(out *PoolStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*PoolStatus) Descriptor ¶ added in v1.0.0
func (*PoolStatus) Descriptor() ([]byte, []int)
func (*PoolStatus) Marshal ¶ added in v1.0.0
func (m *PoolStatus) Marshal() (dAtA []byte, err error)
func (*PoolStatus) MarshalTo ¶ added in v1.0.0
func (m *PoolStatus) MarshalTo(dAtA []byte) (int, error)
func (*PoolStatus) ProtoMessage ¶ added in v1.0.0
func (*PoolStatus) ProtoMessage()
func (*PoolStatus) Reset ¶ added in v1.0.0
func (m *PoolStatus) Reset()
func (*PoolStatus) Size ¶ added in v1.0.0
func (m *PoolStatus) Size() (n int)
func (*PoolStatus) String ¶ added in v1.0.0
func (this *PoolStatus) String() string
func (*PoolStatus) Unmarshal ¶ added in v1.0.0
func (m *PoolStatus) Unmarshal(dAtA []byte) error