Skip to content

Commit

Permalink
Merge pull request #124702 from aojea/automated-cherry-pick-of-#12457…
Browse files Browse the repository at this point in the history
…2-upstream-release-1.30

Automated cherry pick of #124572: tag TrafficDistribution tests to avoid running on
  • Loading branch information
k8s-ci-robot committed May 10, 2024
2 parents 630266c + d17cd6e commit 6c9d03c
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 6 deletions.
2 changes: 1 addition & 1 deletion api/openapi-spec/swagger.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/openapi-spec/v3/api__v1_openapi.json
Expand Up @@ -7562,7 +7562,7 @@
"description": "sessionAffinityConfig contains the configurations of session affinity."
},
"trafficDistribution": {
"description": "TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are topologically close (e.g., same zone).",
"description": "TrafficDistribution offers a way to express preferences for how traffic is distributed to Service endpoints. Implementations can use this field as a hint, but are not required to guarantee strict adherence. If the field is not set, the implementation will apply its default routing strategy. If set to \"PreferClose\", implementations should prioritize endpoints that are topologically close (e.g., same zone). This is an alpha field and requires enabling ServiceTrafficDistribution feature.",
"type": "string"
},
"type": {
Expand Down
2 changes: 1 addition & 1 deletion pkg/generated/openapi/zz_generated.openapi.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions staging/src/k8s.io/api/core/v1/generated.proto

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions staging/src/k8s.io/api/core/v1/types.go
Expand Up @@ -5367,6 +5367,8 @@ type ServiceSpec struct {
// not set, the implementation will apply its default routing strategy. If set
// to "PreferClose", implementations should prioritize endpoints that are
// topologically close (e.g., same zone).
// This is an alpha field and requires enabling ServiceTrafficDistribution feature.
// +featureGate=ServiceTrafficDistribution
// +optional
TrafficDistribution *string `json:"trafficDistribution,omitempty" protobuf:"bytes,23,opt,name=trafficDistribution"`
}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion test/e2e/feature/feature.go
Expand Up @@ -321,9 +321,14 @@ var (
// TODO: document the feature (owning SIG, when to use this feature for a test)
StorageVersionAPI = framework.WithFeature(framework.ValidFeatures.Add("StorageVersionAPI"))

// TODO: document the feature (owning SIG, when to use this feature for a test)
// Owner: sig-network
// Marks tests that require a cluster with Topology Hints enabled.
TopologyHints = framework.WithFeature(framework.ValidFeatures.Add("Topology Hints"))

// Owner: sig-network
// Marks tests that require a cluster with Traffic Distribution enabled.
TrafficDistribution = framework.WithFeature(framework.ValidFeatures.Add("Traffic Distribution"))

// TODO: document the feature (owning SIG, when to use this feature for a test)
TopologyManager = framework.WithFeature(framework.ValidFeatures.Add("TopologyManager"))

Expand Down
3 changes: 2 additions & 1 deletion test/e2e/network/traffic_distribution.go
Expand Up @@ -28,6 +28,7 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/util/intstr"
clientset "k8s.io/client-go/kubernetes"
"k8s.io/kubernetes/test/e2e/feature"
"k8s.io/kubernetes/test/e2e/framework"
e2enode "k8s.io/kubernetes/test/e2e/framework/node"
e2epod "k8s.io/kubernetes/test/e2e/framework/pod"
Expand All @@ -41,7 +42,7 @@ import (
"github.com/onsi/gomega"
)

var _ = common.SIGDescribe("TrafficDistribution", func() {
var _ = common.SIGDescribe(feature.TrafficDistribution, func() {
f := framework.NewDefaultFramework("traffic-distribution")
f.NamespacePodSecurityLevel = admissionapi.LevelPrivileged

Expand Down

0 comments on commit 6c9d03c

Please sign in to comment.