FederatedResourceQuota v1alpha1
apiVersion: policy.karmada.io/v1alpha1
import "github.com/karmada-io/karmada/pkg/apis/policy/v1alpha1"
FederatedResourceQuota
FederatedResourceQuota 用于设置所有集群每个命名空间内强制执行的聚合配额限制。
-
apiVersion:policy.karmada.io/v1alpha1
-
kind:FederatedResourceQuota
-
metadata (ObjectMeta)
-
spec (FederatedResourceQuotaSpec),必选
Spec 规定预期配额。
-
status (FederatedResourceQuotaStatus)
Status 表示实际的强制配额和已使用配额。
FederatedResourceQuotaSpec
FederatedResourceQuotaSpec 定义强制配额的预期硬限制。
-
overall (map[string]Quantity),必选
Overall 是每个命名资源的预期硬限制。
-
staticAssignments ([]StaticClusterAssignment)
StaticAssignments 是每个集群的预期硬限制。注意:对于不在此列表中的集群,Karmada 会将其 ResourceQuota 留空,这些集群在引用的命名空间中没有配额。
StaticClusterAssignment 表示某个指定集群的预期硬限制。
-
staticAssignments.clusterName (string),必选
ClusterName 表示将执行限制的集群的名称。
-
staticAssignments.hard (map[string]Quantity),必选
Hard 表示每个命名资源的预期硬限制。
-
FederatedResourceQuotaStatus
FederatedResourceQuotaStatus 表示强制硬限制和所观测到的使用情况。
-
aggregatedStatus ([]ClusterQuotaStatus)
AggregatedStatus 表示每个集群所观测到的配额使用情况。
ClusterQuotaStatus 表示某个指定集群的预期限制和所观测到的使用情况。
-
aggregatedStatus.clusterName (string),必选
ClusterName 表示将执行限制的集群的名称。
-
aggregatedStatus.hard (map[string]Quantity)
Hard 表示每个命名资源的强制硬限制。更多信息,请浏览 https://kubernetes.io/docs/concepts/policy/resource-quotas/。
-
aggregatedStatus.used (map[string]Quantity)
Used 是当前所观测到的命名空间中资源的总体使用情况。
-
-
overall (map[string]Quantity)
Overall 是每个命名资源的强制硬限制。
-
overallUsed (map[string]Quantity)
OverallUsed 是当前所观测到的命名空间中资源的总体使用情况。
FederatedResourceQuotaList
FederatedResourceQuotaList 罗列 FederatedResourceQuota。
-
apiVersion:policy.karmada.io/v1alpha1
-
kind: FederatedResourceQuotaList
-
metadata (ListMeta)
-
items ([]FederatedResourceQuota), required
操作
get:查询指定的 FederatedResourceQuota
HTTP 请求
GET /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas/{name}
参数
-
名称(路径参数):string,必选
FederatedResourceQuota 的名称
-
namespace(路径参数):string,必选
-
pretty(查询参数):string
响应
200 (FederatedResourceQuota):OK
get:查询指定 FederatedResourceQuota 的状态
HTTP 请求
GET /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas/{name}/status
参数
-
名称(路径参数):string,必选
FederatedResourceQuota 的名称
-
namespace(路径参数):string,必选
-
pretty(查询参数):string
响应
200 (FederatedResourceQuota):OK
list:查询指定命名空间内的所有 FederatedResourceQuota
HTTP 请求
GET /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas
参数
-
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 (FederatedResourceQuotaList):OK
list:查询所有的 FederatedResourceQuota
HTTP 请求
GET /apis/policy.karmada.io/v1alpha1/federatedresourcequotas
参数
-
allowWatchBookmarks(查询参数):boolean
-
continue(查询参数):string
-
fieldSelector(查询参数):string
-
labelSelector(查询参数):string
-
limit(查询参数):integer
-
pretty(查询参数):string
-
resourceVersion(查询参数):string
-
resourceVersionMatch(查询参数):string
-
sendInitialEvents(查询参数):boolean
-
timeoutSeconds(查询参数):integer
-
watch(查询参数):boolean
响应
200 (FederatedResourceQuotaList):OK
create:创建一个 FederatedResourceQuota
HTTP 请求
POST /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas
参数
-
namespace(路径参数):string,必选
-
body: FederatedResourceQuota,必选
-
dryRun(查询参数):string
-
fieldManager(查询参数):string
-
fieldValidation(查询参数):string
-
pretty(查询参数):string
响应
200 (FederatedResourceQuota):OK
201 (FederatedResourceQuota):Created
202 (FederatedResourceQuota):Accepted
update:更新指定的 FederatedResourceQuota
HTTP 请求
PUT /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas/{name}
参数
-
名称(路径参数):string,必选
FederatedResourceQuota 的名称
-
namespace(路径参数):string,必选
-
body: FederatedResourceQuota,必选
-
dryRun(查询参数):string
-
fieldManager(查询参数):string
-
fieldValidation(查询参数):string
-
pretty(查询参数):string
响应
200 (FederatedResourceQuota):OK
201 (FederatedResourceQuota):Created
update:更新指定 FederatedResourceQuota 的状态
HTTP 请求
PUT /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas/{name}/status
参数
-
名称(路径参数):string,必选
FederatedResourceQuota 的名称
-
namespace(路径参数):string,必选
-
body: FederatedResourceQuota,必选
-
dryRun(查询参数):string
-
fieldManager(查询参数):string
-
fieldValidation(查询参数):string
-
pretty(查询参数):string
响应
200 (FederatedResourceQuota):OK
201 (FederatedResourceQuota):Created
patch:更新指定 FederatedResourceQuota 的部分信息
HTTP 请求
PATCH /apis/policy.karmada.io/v1alpha1/namespaces/{namespace}/federatedresourcequotas/{name}