Tag LabelSelector with +structType=atomic

This commit is contained in:
Joe Betz 2020-08-11 11:34:15 -07:00
parent f298d549f6
commit 8874bdf004
8 changed files with 25 additions and 2 deletions

View File

@ -17749,7 +17749,8 @@
"type": "object"
}
},
"type": "object"
"type": "object",
"x-kubernetes-map-type": "atomic"
},
"io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement": {
"description": "A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.",

View File

@ -1718,6 +1718,11 @@ func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common.
},
},
},
VendorExtensible: spec.VendorExtensible{
Extensions: spec.Extensions{
"x-kubernetes-map-type": "atomic",
},
},
},
Dependencies: []string{
"k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement"},

View File

@ -375,6 +375,7 @@ message GroupVersionResource {
// A label selector is a label query over a set of resources. The result of matchLabels and
// matchExpressions are ANDed. An empty label selector matches all objects. A null
// label selector matches no objects.
// +structType=atomic
message LabelSelector {
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
// map is equivalent to an element of matchExpressions, whose key field is "key", the

View File

@ -1092,6 +1092,7 @@ type Patch struct{}
// A label selector is a label query over a set of resources. The result of matchLabels and
// matchExpressions are ANDed. An empty label selector matches all objects. A null
// label selector matches no objects.
// +structType=atomic
type LabelSelector struct {
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
// map is equivalent to an element of matchExpressions, whose key field is "key", the

View File

@ -349,7 +349,7 @@ spec:
expectConflictSet: fieldpath.NewSet(
fieldpath.MakePathOrDie("metadata", "labels", "app"),
fieldpath.MakePathOrDie("spec", "replicas"),
fieldpath.MakePathOrDie("spec", "selector", "matchLabels", "app"),
fieldpath.MakePathOrDie("spec", "selector"), // selector is atomic
fieldpath.MakePathOrDie("spec", "template", "metadata", "labels", "app"),
fieldpath.MakePathOrDie("spec", "template", "spec", "containers", fieldpath.KeyByFields("name", "my-c"), "image"),
),

View File

@ -927,6 +927,11 @@ func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common.
},
},
},
VendorExtensible: spec.VendorExtensible{
Extensions: spec.Extensions{
"x-kubernetes-map-type": "atomic",
},
},
},
Dependencies: []string{
"k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement"},

View File

@ -930,6 +930,11 @@ func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common.
},
},
},
VendorExtensible: spec.VendorExtensible{
Extensions: spec.Extensions{
"x-kubernetes-map-type": "atomic",
},
},
},
Dependencies: []string{
"k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement"},

View File

@ -928,6 +928,11 @@ func schema_pkg_apis_meta_v1_LabelSelector(ref common.ReferenceCallback) common.
},
},
},
VendorExtensible: spec.VendorExtensible{
Extensions: spec.Extensions{
"x-kubernetes-map-type": "atomic",
},
},
},
Dependencies: []string{
"k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelectorRequirement"},