DRA: sync internal API doc comments

This had been done before for types.go, but namedresources.go still had one
small diff.

While at it, fix some typos.
This commit is contained in:
Patrick Ohly 2024-03-27 12:03:24 +01:00
parent 1a13b0aa33
commit acfaf8c275
11 changed files with 22 additions and 14 deletions

View File

@ -9349,7 +9349,7 @@
"type": "string"
},
"resourceClaimName": {
"description": "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. It this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
"description": "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. If this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
"type": "string"
}
},
@ -15026,7 +15026,7 @@
"description": "NamedResourcesFilter is used in ResourceFilterModel.",
"properties": {
"selector": {
"description": "Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/\n\nIn addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example:\n\n attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) &&\n attributes.stringslice[\"b\"].isSorted()",
"description": "Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/\n\nIn addition, for each type in NamedResourcesAttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example:\n\n attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) &&\n attributes.stringslice[\"b\"].isSorted()",
"type": "string"
}
},

View File

@ -5221,7 +5221,7 @@
"type": "string"
},
"resourceClaimName": {
"description": "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. It this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
"description": "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. If this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
"type": "string"
}
},

View File

@ -244,7 +244,7 @@
"properties": {
"selector": {
"default": "",
"description": "Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/\n\nIn addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example:\n\n attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) &&\n attributes.stringslice[\"b\"].isSorted()",
"description": "Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/\n\nIn addition, for each type in NamedResourcesAttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example:\n\n attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) &&\n attributes.stringslice[\"b\"].isSorted()",
"type": "string"
}
},

View File

@ -3477,7 +3477,7 @@ type PodResourceClaimStatus struct {
Name string
// ResourceClaimName is the name of the ResourceClaim that was
// generated for the Pod in the namespace of the Pod. It this is
// generated for the Pod in the namespace of the Pod. If this is
// unset, then generating a ResourceClaim was not necessary. The
// pod.spec.resourceClaims entry can be ignored in this case.
ResourceClaimName *string

View File

@ -92,8 +92,16 @@ type NamedResourcesRequest struct {
// NamedResourcesFilter is used in ResourceFilterModel.
type NamedResourcesFilter struct {
// Selector is a selector like the one in Request. It must be true for
// a resource instance to be suitable for a claim using the class.
// Selector is a CEL expression which must evaluate to true if a
// resource instance is suitable. The language is as defined in
// https://kubernetes.io/docs/reference/using-api/cel/
//
// In addition, for each type in NamedResourcesAttributeValue there is a map that
// resolves to the corresponding value of the instance under evaluation.
// For example:
//
// attributes.quantity["a"].isGreaterThan(quantity("0")) &&
// attributes.stringslice["b"].isSorted()
Selector string
}

View File

@ -26996,7 +26996,7 @@ func schema_k8sio_api_core_v1_PodResourceClaimStatus(ref common.ReferenceCallbac
},
"resourceClaimName": {
SchemaProps: spec.SchemaProps{
Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. It this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
Description: "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. If this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
Type: []string{"string"},
Format: "",
},
@ -45215,7 +45215,7 @@ func schema_k8sio_api_resource_v1alpha2_NamedResourcesFilter(ref common.Referenc
Properties: map[string]spec.Schema{
"selector": {
SchemaProps: spec.SchemaProps{
Description: "Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/\n\nIn addition, for each type NamedResourcesin AttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example:\n\n attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) &&\n attributes.stringslice[\"b\"].isSorted()",
Description: "Selector is a CEL expression which must evaluate to true if a resource instance is suitable. The language is as defined in https://kubernetes.io/docs/reference/using-api/cel/\n\nIn addition, for each type in NamedResourcesAttributeValue there is a map that resolves to the corresponding value of the instance under evaluation. For example:\n\n attributes.quantity[\"a\"].isGreaterThan(quantity(\"0\")) &&\n attributes.stringslice[\"b\"].isSorted()",
Default: "",
Type: []string{"string"},
Format: "",

View File

@ -3813,7 +3813,7 @@ message PodResourceClaimStatus {
optional string name = 1;
// ResourceClaimName is the name of the ResourceClaim that was
// generated for the Pod in the namespace of the Pod. It this is
// generated for the Pod in the namespace of the Pod. If this is
// unset, then generating a ResourceClaim was not necessary. The
// pod.spec.resourceClaims entry can be ignored in this case.
//

View File

@ -3929,7 +3929,7 @@ type PodResourceClaimStatus struct {
Name string `json:"name" protobuf:"bytes,1,name=name"`
// ResourceClaimName is the name of the ResourceClaim that was
// generated for the Pod in the namespace of the Pod. It this is
// generated for the Pod in the namespace of the Pod. If this is
// unset, then generating a ResourceClaim was not necessary. The
// pod.spec.resourceClaims entry can be ignored in this case.
//

View File

@ -1708,7 +1708,7 @@ func (PodResourceClaim) SwaggerDoc() map[string]string {
var map_PodResourceClaimStatus = map[string]string{
"": "PodResourceClaimStatus is stored in the PodStatus for each PodResourceClaim which references a ResourceClaimTemplate. It stores the generated name for the corresponding ResourceClaim.",
"name": "Name uniquely identifies this resource claim inside the pod. This must match the name of an entry in pod.spec.resourceClaims, which implies that the string must be a DNS_LABEL.",
"resourceClaimName": "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. It this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
"resourceClaimName": "ResourceClaimName is the name of the ResourceClaim that was generated for the Pod in the namespace of the Pod. If this is unset, then generating a ResourceClaim was not necessary. The pod.spec.resourceClaims entry can be ignored in this case.",
}
func (PodResourceClaimStatus) SwaggerDoc() map[string]string {

View File

@ -145,7 +145,7 @@ message NamedResourcesFilter {
// resource instance is suitable. The language is as defined in
// https://kubernetes.io/docs/reference/using-api/cel/
//
// In addition, for each type NamedResourcesin AttributeValue there is a map that
// In addition, for each type in NamedResourcesAttributeValue there is a map that
// resolves to the corresponding value of the instance under evaluation.
// For example:
//

View File

@ -111,7 +111,7 @@ type NamedResourcesFilter struct {
// resource instance is suitable. The language is as defined in
// https://kubernetes.io/docs/reference/using-api/cel/
//
// In addition, for each type NamedResourcesin AttributeValue there is a map that
// In addition, for each type in NamedResourcesAttributeValue there is a map that
// resolves to the corresponding value of the instance under evaluation.
// For example:
//