diff --git a/.gitlab/benchmarks.yml b/.gitlab/benchmarks.yml index 8b621365070..3f6716fd67b 100644 --- a/.gitlab/benchmarks.yml +++ b/.gitlab/benchmarks.yml @@ -68,6 +68,36 @@ benchmarks-post-results: - job: benchmarks-dacapo artifacts: true +check-big-regressions: + extends: .benchmarks + needs: + - job: benchmarks-startup + artifacts: true + - job: benchmarks-load + artifacts: true + when: on_success + tags: ["arch:amd64"] + # ARTIFACTS_DIR /go/src/github.com/DataDog/apm-reliability/dd-trace-java/reports/ + # need to convert them + script: + - !reference [ .benchmarks, script ] + - | + for benchmarkType in startup load; do + find "$ARTIFACTS_DIR/$benchmarkType" -name "benchmark-baseline.json" -o -name "benchmark-candidate.json" | while read file; do + relpath="${file#$ARTIFACTS_DIR/$benchmarkType/}" + prefix="${relpath%/benchmark-*}" # Remove the trailing /benchmark-(baseline|candidate).json + prefix="${prefix#./}" # Remove any leading ./ + prefix="${prefix//\//-}" # Replace / with - + case "$file" in + *benchmark-baseline.json) type="baseline" ;; + *benchmark-candidate.json) type="candidate" ;; + esac + echo "Moving $file to $ARTIFACTS_DIR/${type}-${prefix}.converted.json" + cp "$file" "$ARTIFACTS_DIR/${type}-${prefix}.converted.json" + done + done + - bp-runner $CI_PROJECT_DIR/.gitlab/benchmarks/bp-runner.fail-on-regression.yml --debug + .dsm-kafka-benchmarks: stage: benchmarks rules: diff --git a/.gitlab/benchmarks/bp-runner.fail-on-regression.yml b/.gitlab/benchmarks/bp-runner.fail-on-regression.yml new file mode 100644 index 00000000000..fc63ef88e96 --- /dev/null +++ b/.gitlab/benchmarks/bp-runner.fail-on-regression.yml @@ -0,0 +1,7 @@ +experiments: + - name: Run regression check + steps: + - name: Regression Check + run: fail_on_regression + # Applies on all scenarios + regression_threshold: 20.0 # percents