Skip to content

Commit

Permalink
Fix perf patch for release 1.14
Browse files Browse the repository at this point in the history
  • Loading branch information
ReToCode committed Apr 29, 2024
1 parent 8e2c6da commit 42ed6d2
Showing 1 changed file with 24 additions and 24 deletions.
48 changes: 24 additions & 24 deletions openshift/performance/patches/perf.patch
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
diff --git a/Makefile b/Makefile
index 21872e521..45b7b7e22 100644
index ccd342372..7963cf412 100644
--- a/Makefile
+++ b/Makefile
@@ -6,6 +6,7 @@ CORE_IMAGES=./cmd/activator ./cmd/autoscaler ./cmd/autoscaler-hpa ./cmd/controll
Expand Down Expand Up @@ -36,30 +36,30 @@ index 21872e521..45b7b7e22 100644

# Generate an aggregated knative yaml file with replaced image references
diff --git a/openshift/ci-operator/Dockerfile.in b/openshift/ci-operator/Dockerfile.in
index 32b94bfb1..ce192d43d 100644
index 1c31865cc..7bd47161b 100644
--- a/openshift/ci-operator/Dockerfile.in
+++ b/openshift/ci-operator/Dockerfile.in
@@ -2,7 +2,7 @@
FROM registry.ci.openshift.org/openshift/release:rhel-8-release-golang-1.21-openshift-4.16 as builder
FROM registry.ci.openshift.org/openshift/release:golang-1.21 as builder

COPY . .
-RUN make install test-install
+RUN make install test-install perf-install

FROM openshift/origin-base
FROM registry.access.redhat.com/ubi8/ubi-minimal
USER 65532
diff --git a/openshift/ci-operator/Dockerfile_with_kodata.in b/openshift/ci-operator/Dockerfile_with_kodata.in
index 00de72095..0422ce541 100644
index 9d84e5ecc..572d91c25 100644
--- a/openshift/ci-operator/Dockerfile_with_kodata.in
+++ b/openshift/ci-operator/Dockerfile_with_kodata.in
@@ -2,7 +2,7 @@
FROM registry.ci.openshift.org/openshift/release:rhel-8-release-golang-1.21-openshift-4.16 as builder
FROM registry.ci.openshift.org/openshift/release:golang-1.21 as builder

COPY . .
-RUN make install test-install
+RUN make install test-install perf-install

FROM openshift/origin-base
FROM registry.access.redhat.com/ubi8/ubi-minimal
USER 65532
diff --git a/test/performance/README.md b/test/performance/README.md
index a4906039a..f17f7cffc 100644
Expand Down Expand Up @@ -264,7 +264,7 @@ index 63737a5df..6fc01ccd6 100644
seccompProfile:
type: RuntimeDefault
diff --git a/test/performance/benchmarks/dataplane-probe/main.go b/test/performance/benchmarks/dataplane-probe/main.go
index f17996dc9..09e9fcadf 100644
index 58693daa3..ff0a8b37b 100644
--- a/test/performance/benchmarks/dataplane-probe/main.go
+++ b/test/performance/benchmarks/dataplane-probe/main.go
@@ -118,11 +118,11 @@ func main() {
Expand Down Expand Up @@ -299,7 +299,7 @@ index f17996dc9..09e9fcadf 100644
+ reporter.AddDataPointsForMetrics(metricResults, benchmarkName)
_ = vegeta.NewTextReporter(metricResults).Report(os.Stdout)

if err := checkSLA(metricResults, t.slaMin, t.slaMax); err != nil {
if err := checkSLA(metricResults, t.slaMin, t.slaMax, rate, *duration); err != nil {
// make sure to still write the stats
- influxReporter.FlushAndShutdown()
+ reporter.FlushAndShutdown()
Expand Down Expand Up @@ -442,7 +442,7 @@ index 64c1e99a5..2c7b6295d 100644
valueFrom:
secretKeyRef:
diff --git a/test/performance/benchmarks/load-test/main.go b/test/performance/benchmarks/load-test/main.go
index 822eff669..f5b18ea28 100644
index 4e55b942d..336bb88da 100644
--- a/test/performance/benchmarks/load-test/main.go
+++ b/test/performance/benchmarks/load-test/main.go
@@ -62,11 +62,11 @@ func main() {
Expand Down Expand Up @@ -472,7 +472,7 @@ index 822eff669..f5b18ea28 100644
+ reporter.AddDataPointsForMetrics(metricResults, benchmarkName)
_ = vegeta.NewTextReporter(metricResults).Report(os.Stdout)

if err := checkSLA(metricResults); err != nil {
if err := checkSLA(metricResults, pacers, durations); err != nil {
// make sure to still write the stats
- influxReporter.FlushAndShutdown()
+ reporter.FlushAndShutdown()
Expand Down Expand Up @@ -510,7 +510,7 @@ index 822eff669..f5b18ea28 100644
}
}
diff --git a/test/performance/benchmarks/real-traffic-test/main.go b/test/performance/benchmarks/real-traffic-test/main.go
index bd034c41d..db18a12f6 100644
index bad45b394..718831c64 100644
--- a/test/performance/benchmarks/real-traffic-test/main.go
+++ b/test/performance/benchmarks/real-traffic-test/main.go
@@ -115,11 +115,11 @@ func main() {
Expand All @@ -536,7 +536,7 @@ index bd034c41d..db18a12f6 100644
+ reporter.AddDataPointsForMetrics(metricResults, benchmarkName)
_ = vegeta.NewTextReporter(metricResults).Report(os.Stdout)

if err := checkSLA(metricResults); err != nil {
if err := checkSLA(metricResults, rate); err != nil {
cleanup()
- influxReporter.FlushAndShutdown()
+ reporter.FlushAndShutdown()
Expand Down Expand Up @@ -806,10 +806,10 @@ index 3f5be345a..a78680542 100644
valueFrom:
secretKeyRef:
diff --git a/test/performance/benchmarks/rollout-probe/main.go b/test/performance/benchmarks/rollout-probe/main.go
index b374fe485..da6dbfba3 100644
index 288125138..8f1144ea0 100644
--- a/test/performance/benchmarks/rollout-probe/main.go
+++ b/test/performance/benchmarks/rollout-probe/main.go
@@ -113,11 +113,11 @@ func main() {
@@ -114,11 +114,11 @@ func main() {
})
log.Print("Running rollout probe test with selector: ", selector)

Expand All @@ -824,7 +824,7 @@ index b374fe485..da6dbfba3 100644

// Setup background metric processes
deploymentStatus := performance.FetchDeploymentsStatus(ctx, namespace, selector, time.Second)
@@ -174,12 +174,12 @@ LOOP:
@@ -175,12 +175,12 @@ LOOP:
// If it is the first one -- report it.
if strings.Contains(ds.DeploymentName, firstRev) {
// Add a sample point for the deployment status.
Expand All @@ -841,15 +841,15 @@ index b374fe485..da6dbfba3 100644
// Ignore all other revisions' deployments if there are, since
// they are from previous test run iterations, and we don't care about
// their reported scale values (should be 0 & 100 depending on which
@@ -207,12 +207,12 @@ LOOP:
@@ -208,12 +208,12 @@ LOOP:
metricResults.Close()

// Report the results
- influxReporter.AddDataPointsForMetrics(metricResults, benchmarkName)
+ reporter.AddDataPointsForMetrics(metricResults, benchmarkName)
_ = vegeta.NewTextReporter(metricResults).Report(os.Stdout)

if err := checkSLA(metricResults); err != nil {
if err := checkSLA(metricResults, rate); err != nil {
// make sure to still write the stats
- influxReporter.FlushAndShutdown()
+ reporter.FlushAndShutdown()
Expand Down Expand Up @@ -992,10 +992,10 @@ index 59705f94a..60ef86ae1 100644
valueFrom:
secretKeyRef:
diff --git a/test/performance/benchmarks/scale-from-zero/main.go b/test/performance/benchmarks/scale-from-zero/main.go
index 64e9cafa3..5e58841f0 100644
index 2c527c74b..886847e42 100644
--- a/test/performance/benchmarks/scale-from-zero/main.go
+++ b/test/performance/benchmarks/scale-from-zero/main.go
@@ -129,11 +129,11 @@ func main() {
@@ -127,11 +127,11 @@ func main() {
log.Fatal("Failed to setup clients: ", err)
}

Expand All @@ -1010,7 +1010,7 @@ index 64e9cafa3..5e58841f0 100644

// We use vegeta.Metrics here as a metrics collector because it already contains logic to calculate percentiles
vegetaReporter := performance.NewVegetaReporter()
@@ -157,18 +157,18 @@ func main() {
@@ -155,18 +155,18 @@ func main() {
fatalf("Failed to wait for all services to scale to zero: %v", err)
}

Expand All @@ -1025,14 +1025,14 @@ index 64e9cafa3..5e58841f0 100644
_ = vegeta.NewTextReporter(metricResults).Report(os.Stdout)

sla := slas[*parallelCount]
if err := checkSLA(metricResults, sla.p95min, sla.p95max, sla.latencyMax); err != nil {
if err := checkSLA(metricResults, sla.p95min, sla.p95max, sla.latencyMax, *parallelCount); err != nil {
// make sure to still write the stats
- influxReporter.FlushAndShutdown()
+ reporter.FlushAndShutdown()
log.Fatalf(err.Error())
}

@@ -252,7 +252,7 @@ func waitForScaleToZero(ctx context.Context, objs []*v1test.ResourceObjects) err
@@ -250,7 +250,7 @@ func waitForScaleToZero(ctx context.Context, objs []*v1test.ResourceObjects) err
return g.Wait()
}

Expand All @@ -1041,7 +1041,7 @@ index 64e9cafa3..5e58841f0 100644
count := len(objs)
var wg sync.WaitGroup
wg.Add(count)
@@ -263,16 +263,16 @@ func parallelScaleFromZero(ctx context.Context, clients *test.Clients, objs []*v
@@ -261,16 +261,16 @@ func parallelScaleFromZero(ctx context.Context, clients *test.Clients, objs []*v
serviceReadyDuration, deploymentUpdatedDuration, err := runScaleFromZero(ctx, clients, ndx, objs[ndx])
if err == nil {
vegetaReporter.AddResult(&vegeta.Result{Latency: serviceReadyDuration})
Expand Down

0 comments on commit 42ed6d2

Please sign in to comment.