Skip to content

Commit

Permalink
Move our CI to GKE 1.21 (#12509)
Browse files Browse the repository at this point in the history
* bump GKE to 1.21

* clean up comments

* set a 60s stabilization window for the HPA e2e test

With GKE 1.21 I'm seeing this test fail regularly. My assumption is the scaling algorithms have changed
or have different timings. So rather than rely on the default 5 minute window let's make adjustments more aggresively.

* disable TestToScaleN due to it being really flakey with GKE 1.21
  • Loading branch information
dprotaso authored Jan 20, 2022
1 parent bd2a436 commit 30f5c96
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 18 deletions.
7 changes: 1 addition & 6 deletions test/e2e-auto-tls-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,7 @@ function delete_dns_record() {
}

# Script entry point.

# Skip installing istio as an add-on
# Temporarily increasing the cluster size for serving tests to rule out
# resource/eviction as causes of flakiness.
# Pin to 1.20 since scale test is super flakey on 1.21
initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.20
initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.21

# Run the tests
header "Running tests"
Expand Down
10 changes: 3 additions & 7 deletions test/e2e-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,7 @@
source $(dirname $0)/e2e-common.sh

# Script entry point.

# Skip installing istio as an add-on.
# Temporarily increasing the cluster size for serving tests to rule out
# resource/eviction as causes of flakiness.
# Pin to 1.20 since scale test is super flakey on 1.21
initialize --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.20 "$@"
initialize --skip-istio-addon --min-nodes=4 --max-nodes=4 --enable-ha --cluster-version=1.21 "$@"

# Run the tests
header "Running tests"
Expand Down Expand Up @@ -112,7 +107,8 @@ kubectl replace cm "config-gc" -n ${SYSTEM_NAMESPACE} -f ${TMP_DIR}/config-gc.ya
# Note that we use a very high -parallel because each ksvc is run as its own
# sub-test. If this is not larger than the maximum scale tested then the test
# simply cannot pass.
go_test_e2e -timeout=20m -parallel=300 ./test/scale ${TEST_OPTIONS} || failed=1
# TODO - Renable once we get this reliably passing on GKE 1.21
# go_test_e2e -timeout=20m -parallel=300 ./test/scale ${TEST_OPTIONS} || failed=1

# Run HPA tests
go_test_e2e -timeout=30m -tags=hpa ./test/e2e ${TEST_OPTIONS} || failed=1
Expand Down
5 changes: 1 addition & 4 deletions test/e2e-upgrade-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,7 @@ function stage_test_resources() {
# Script entry point.

# Skip installing istio as an add-on.
# Temporarily increasing the cluster size for serving tests to rule out
# resource/eviction as causes of flakiness.
# Pin to 1.20 since scale test is super flakey on 1.21
initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --cluster-version=1.20 \
initialize "$@" --skip-istio-addon --min-nodes=4 --max-nodes=4 --cluster-version=1.21 \
--install-latest-release

# TODO(#2656): Reduce the timeout after we get this test to consistently passing.
Expand Down
3 changes: 2 additions & 1 deletion test/e2e/autoscale_hpa_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ func setupHPASvc(t *testing.T, metric string, target int) *TestContext {
autoscaling.MetricAnnotationKey: metric,
autoscaling.TargetAnnotationKey: strconv.Itoa(target),
autoscaling.MaxScaleAnnotationKey: fmt.Sprintf("%d", int(maxPods)),
autoscaling.WindowAnnotationKey: "20s",
}), rtesting.WithResourceRequirements(corev1.ResourceRequirements{
Requests: corev1.ResourceList{
corev1.ResourceCPU: resource.MustParse("30m"),
Expand Down Expand Up @@ -253,7 +254,7 @@ func waitForHPAState(t *testing.T, name, namespace string, clients *test.Clients
return false, err
}
if hpa.Status.CurrentMetrics == nil {
t.Logf("Waiting for hpa.status is available: %v", hpa.Status)
t.Logf("Waiting for hpa.status is available: %#v", hpa.Status)
return false, nil
}
return true, nil
Expand Down

0 comments on commit 30f5c96

Please sign in to comment.