PodSchedulingContext v1alpha3
apiVersion: resource.k8s.io/v1alpha3
import "k8s.io/api/resource/v1alpha3"
PodSchedulingContext
PodSchedulingContext 对象包含调度某些 Pod 所需要的额外信息,这些 Pod 使用了 “WaitForFirstConsumer” 分配模式的 ResourceClaim。
本功能特性是 Alpha 级别的特性,需要启用 DRAControlPlaneController 特性门控。
- 
apiVersion: resource.k8s.io/v1alpha3
 - 
kind: PodSchedulingContext
 - 
metadata (ObjectMeta)
标准的对象元数据。
 
- 
spec (PodSchedulingContextSpec),必需
spec 描述了 Pod 需要在哪里找到资源。
 - 
status (PodSchedulingContextStatus)
status 描述了 Pod 的资源可以在哪里分配。
 
PodSchedulingContextSpec
PodSchedulingContextSpec 描述了 Pod 所需要的资源在哪里。
- 
potentialNodes ([]string)
原子:将在合并期间被替换
potentialNodes 列出可以运行 Pod 的节点。
该字段的大小限制为 128。对于许多集群来说,这已经足够大了。 较大的集群可能需要更多的尝试去找到一个适合所有待定资源的节点。 这个限制值可能会在以后提高,但不会降低。
 - 
selectedNode (string)
selectedNode 是一个节点,由 Pod 引用的 ResourceClaim 将在此节点上尝试, 且尝试的分配模式是 “WaitForFirstConsumer”。
 
PodSchedulingContextStatus
PodSchedulingContextStatus 描述 Pod 的资源可以从哪里分配。
- 
resourceClaims ([]ResourceClaimSchedulingStatus)
映射:键
name的唯一值将在合并过程中保留resourceClaims 描述了每个 pod.spec.resourceClaim 条目的资源可用性, 其中对应的 ResourceClaim 使用 “WaitForFirstConsumer” 分配模式。
ResourceClaimSchedulingStatus 包含关于一个采用 “WaitForFirstConsumer” 分配模式的特定 ResourceClaim 的信息。
- 
resourceClaims.name (string)
name 与 pod.spec.resourceClaims[*].name 字段匹配。
 - 
resourceClaims.unsuitableNodes ([]string)
原子:将在合并期间被替换
unsuitableNodes 列出 ResourceClaim 无法被分配的节点。
该字段的大小限制为 128,与 PodSchedulingSpec.PotentialNodes 相同。 这可能会在以后增加,但不会减少。
 
 - 
 
PodSchedulingContextList
PodSchedulingContextList 是 Pod 调度对象的集合。
- 
apiVersion: resource.k8s.io/v1alpha3
 - 
kind: PodSchedulingContextList
 - 
metadata (ListMeta)
标准的列表元数据。
 
- 
items ([]PodSchedulingContext),必需
items 是 PodSchedulingContext 对象的列表。
 
操作
get 读取指定的 PodSchedulingContext
HTTP 请求
GET /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
401: Unauthorized
get 读取指定 PodSchedulingContext 的状态
HTTP 请求
GET /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}/status
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
401: Unauthorized
list 列出或监视 PodSchedulingContext 类别的对象
HTTP 请求
GET /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts
参数
- 
namespace(路径参数):string,必需
 - 
allowWatchBookmarks(查询参数):boolean
 - 
continue(查询参数):string
 - 
fieldSelector(查询参数):string
 - 
labelSelector(查询参数):string
 - 
limit(查询参数):integer
 - 
pretty(查询参数):string
 - 
resourceVersion(查询参数):string
 - 
resourceVersionMatch(查询参数):string
 - 
sendInitialEvents(查询参数):boolean
 - 
timeoutSeconds(查询参数):integer
 - 
watch(查询参数):boolean
 
响应
200 (PodSchedulingContextList): OK
401: Unauthorized
list 列出或监视 PodSchedulingContext 类别的对象
HTTP 请求
GET /apis/resource.k8s.io/v1alpha3/podschedulingcontexts
参数
- 
allowWatchBookmarks(查询参数):boolean
 - 
continue(查询参数):string
 - 
fieldSelector(查询参数):string
 - 
labelSelector(查询参数):string
 - 
limit(查询参数):integer
 - 
pretty(查询参数):string
 - 
resourceVersion(查询参数):string
 - 
resourceVersionMatch(查询参数):string
 - 
sendInitialEvents(查询参数):boolean
 - 
timeoutSeconds(查询参数):integer
 - 
watch(查询参数):boolean
 
响应
200 (PodSchedulingContextList): OK
401: Unauthorized
create 创建 PodSchedulingContext
HTTP 请求
POST /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts
参数
- 
namespace(路径参数):string,必需
 - 
body: PodSchedulingContext,必需
 - 
dryRun(查询参数):string
 - 
fieldManager(查询参数):string
 - 
fieldValidation(查询参数):string
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
201 (PodSchedulingContext): Created
202 (PodSchedulingContext): Accepted
401: Unauthorized
update 替换指定的 PodSchedulingContext
HTTP 请求
PUT /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
body: PodSchedulingContext,必需
 - 
dryRun(查询参数):string
 - 
fieldManager(查询参数):string
 - 
fieldValidation(查询参数):string
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
201 (PodSchedulingContext): Created
401: Unauthorized
update 替换指定 PodSchedulingContext 的状态
HTTP 请求
PUT /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}/status
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
body: PodSchedulingContext,必需
 - 
dryRun(查询参数):string
 - 
fieldManager(查询参数):string
 - 
fieldValidation(查询参数):string
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
201 (PodSchedulingContext): Created
401: Unauthorized
patch 部分更新指定的 PodSchedulingContext
HTTP 请求
PATCH /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
body: Patch,必需
 - 
dryRun(查询参数):string
 - 
fieldManager(查询参数):string
 - 
fieldValidation(查询参数):string
 - 
force(查询参数):boolean
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
201 (PodSchedulingContext): Created
401: Unauthorized
patch 部分更新指定 PodSchedulingContext 的状态
HTTP 请求
PATCH /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}/status
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
body: Patch,必需
 - 
dryRun(查询参数):string
 - 
fieldManager(查询参数):string
 - 
fieldValidation(查询参数):string
 - 
force(查询参数):boolean
 - 
pretty(查询参数):string
 
响应
200 (PodSchedulingContext): OK
201 (PodSchedulingContext): Created
401: Unauthorized
delete 删除 PodSchedulingContext
HTTP 请求
DELETE /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts/{name}
参数
- 
name(路径参数):string,必需
PodSchedulingContext 的名称。
 - 
namespace(路径参数):string,必需
 - 
body: DeleteOptions
 - 
dryRun(查询参数):string
 - 
gracePeriodSeconds(查询参数):integer
 - 
pretty(查询参数):string
 - 
propagationPolicy(查询参数):string
 
响应
200 (PodSchedulingContext): OK
202 (PodSchedulingContext): Accepted
401: Unauthorized
deletecollection 删除 PodSchedulingContext 的集合
HTTP 请求
DELETE /apis/resource.k8s.io/v1alpha3/namespaces/{namespace}/podschedulingcontexts
参数
- 
namespace(路径参数):string,必需
 - 
body: DeleteOptions
 - 
continue(查询参数):string
 - 
dryRun(查询参数):string
 - 
fieldSelector(查询参数):string
 - 
gracePeriodSeconds(查询参数):integer
 - 
labelSelector(查询参数):string
 - 
limit(查询参数):integer
 - 
pretty(查询参数):string
 - 
propagationPolicy(查询参数):string
 - 
resourceVersion(查询参数):string
 - 
resourceVersionMatch(查询参数):string
 - 
sendInitialEvents(查询参数):boolean
 - 
timeoutSeconds(查询参数):integer
 
响应
200 (Status): OK
401: Unauthorized