update generate docs for PreferSameTrafficDistribution

This commit is contained in:
Dan Winship
2025-02-11 10:06:25 -05:00
parent 4435ead24a
commit af3584778e
27 changed files with 1024 additions and 120 deletions

View File

@@ -633,6 +633,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA
"k8s.io/api/discovery/v1.EndpointPort": schema_k8sio_api_discovery_v1_EndpointPort(ref),
"k8s.io/api/discovery/v1.EndpointSlice": schema_k8sio_api_discovery_v1_EndpointSlice(ref),
"k8s.io/api/discovery/v1.EndpointSliceList": schema_k8sio_api_discovery_v1_EndpointSliceList(ref),
"k8s.io/api/discovery/v1.ForNode": schema_k8sio_api_discovery_v1_ForNode(ref),
"k8s.io/api/discovery/v1.ForZone": schema_k8sio_api_discovery_v1_ForZone(ref),
"k8s.io/api/discovery/v1beta1.Endpoint": schema_k8sio_api_discovery_v1beta1_Endpoint(ref),
"k8s.io/api/discovery/v1beta1.EndpointConditions": schema_k8sio_api_discovery_v1beta1_EndpointConditions(ref),
@@ -640,6 +641,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA
"k8s.io/api/discovery/v1beta1.EndpointPort": schema_k8sio_api_discovery_v1beta1_EndpointPort(ref),
"k8s.io/api/discovery/v1beta1.EndpointSlice": schema_k8sio_api_discovery_v1beta1_EndpointSlice(ref),
"k8s.io/api/discovery/v1beta1.EndpointSliceList": schema_k8sio_api_discovery_v1beta1_EndpointSliceList(ref),
"k8s.io/api/discovery/v1beta1.ForNode": schema_k8sio_api_discovery_v1beta1_ForNode(ref),
"k8s.io/api/discovery/v1beta1.ForZone": schema_k8sio_api_discovery_v1beta1_ForZone(ref),
"k8s.io/api/events/v1.Event": schema_k8sio_api_events_v1_Event(ref),
"k8s.io/api/events/v1.EventList": schema_k8sio_api_events_v1_EventList(ref),
@@ -33601,7 +33603,7 @@ func schema_k8sio_api_discovery_v1_EndpointHints(ref common.ReferenceCallback) c
},
},
SchemaProps: spec.SchemaProps{
Description: "forZones indicates the zone(s) this endpoint should be consumed by to enable topology aware routing.",
Description: "forZones indicates the zone(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries.",
Type: []string{"array"},
Items: &spec.SchemaOrArray{
Schema: &spec.Schema{
@@ -33613,11 +33615,30 @@ func schema_k8sio_api_discovery_v1_EndpointHints(ref common.ReferenceCallback) c
},
},
},
"forNodes": {
VendorExtensible: spec.VendorExtensible{
Extensions: spec.Extensions{
"x-kubernetes-list-type": "atomic",
},
},
SchemaProps: spec.SchemaProps{
Description: "forNodes indicates the node(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. This is an Alpha feature and is only used when the PreferSameTrafficDistribution feature gate is enabled.",
Type: []string{"array"},
Items: &spec.SchemaOrArray{
Schema: &spec.Schema{
SchemaProps: spec.SchemaProps{
Default: map[string]interface{}{},
Ref: ref("k8s.io/api/discovery/v1.ForNode"),
},
},
},
},
},
},
},
},
Dependencies: []string{
"k8s.io/api/discovery/v1.ForZone"},
"k8s.io/api/discovery/v1.ForNode", "k8s.io/api/discovery/v1.ForZone"},
}
}
@@ -33803,6 +33824,28 @@ func schema_k8sio_api_discovery_v1_EndpointSliceList(ref common.ReferenceCallbac
}
}
func schema_k8sio_api_discovery_v1_ForNode(ref common.ReferenceCallback) common.OpenAPIDefinition {
return common.OpenAPIDefinition{
Schema: spec.Schema{
SchemaProps: spec.SchemaProps{
Description: "ForNode provides information about which nodes should consume this endpoint.",
Type: []string{"object"},
Properties: map[string]spec.Schema{
"name": {
SchemaProps: spec.SchemaProps{
Description: "name represents the name of the node.",
Default: "",
Type: []string{"string"},
Format: "",
},
},
},
Required: []string{"name"},
},
},
}
}
func schema_k8sio_api_discovery_v1_ForZone(ref common.ReferenceCallback) common.OpenAPIDefinition {
return common.OpenAPIDefinition{
Schema: spec.Schema{
@@ -33970,11 +34013,30 @@ func schema_k8sio_api_discovery_v1beta1_EndpointHints(ref common.ReferenceCallba
},
},
},
"forNodes": {
VendorExtensible: spec.VendorExtensible{
Extensions: spec.Extensions{
"x-kubernetes-list-type": "atomic",
},
},
SchemaProps: spec.SchemaProps{
Description: "forNodes indicates the node(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. This is an Alpha feature and is only used when the PreferSameTrafficDistribution feature gate is enabled.",
Type: []string{"array"},
Items: &spec.SchemaOrArray{
Schema: &spec.Schema{
SchemaProps: spec.SchemaProps{
Default: map[string]interface{}{},
Ref: ref("k8s.io/api/discovery/v1beta1.ForNode"),
},
},
},
},
},
},
},
},
Dependencies: []string{
"k8s.io/api/discovery/v1beta1.ForZone"},
"k8s.io/api/discovery/v1beta1.ForNode", "k8s.io/api/discovery/v1beta1.ForZone"},
}
}
@@ -34154,6 +34216,28 @@ func schema_k8sio_api_discovery_v1beta1_EndpointSliceList(ref common.ReferenceCa
}
}
func schema_k8sio_api_discovery_v1beta1_ForNode(ref common.ReferenceCallback) common.OpenAPIDefinition {
return common.OpenAPIDefinition{
Schema: spec.Schema{
SchemaProps: spec.SchemaProps{
Description: "ForNode provides information about which nodes should consume this endpoint.",
Type: []string{"object"},
Properties: map[string]spec.Schema{
"name": {
SchemaProps: spec.SchemaProps{
Description: "name represents the name of the node.",
Default: "",
Type: []string{"string"},
Format: "",
},
},
},
Required: []string{"name"},
},
},
}
}
func schema_k8sio_api_discovery_v1beta1_ForZone(ref common.ReferenceCallback) common.OpenAPIDefinition {
return common.OpenAPIDefinition{
Schema: spec.Schema{