Name Date Size #Lines LOC

..--

src/main/H25-Apr-2025-9,7447,398

README.mdH A D25-Apr-20251.3 KiB3927

pom.xmlH A D25-Apr-202515.9 KiB408351

README.md

1# Sdk Benchmark Harness
2
3
4This module contains sdk benchmark harness using [JMH].
5
6Each benchmark class has a set of default
7JMH configurations tailored to SDK's build job and you might need to
8adjust them based on your test environment such as increasing warmup iterations
9or measurement time in order to get more reliable data.
10
11There are three ways to run benchmarks.
12
13- Using the executable JAR (Preferred usage per JMH site)
14```bash
15mvn clean install -P quick -pl :sdk-benchmarks --am
16
17# Run specific benchmark
18java -jar target/benchmarks.jar ApacheHttpClientBenchmark
19
20# Run all benchmarks: 3 warm up iterations, 3 benchmark iterations, 1 fork
21java -jar target/benchmarks.jar -wi 3 -i 3 -f 1
22```
23
24- Using`mvn exec:exec` commands to invoke `BenchmarkRunner` main method
25```bash
26   mvn clean install -P quick -pl :sdk-benchmarks --am
27   mvn clean install -pl :bom-internal
28   cd test/sdk-benchmarks
29   mvn exec:exec
30```
31
32- From IDE
33
34  You can run the main method within each Benchmark class from your IDE. If you are using Eclipse, you might need to
35  set up build configurations for JMH annotation, please check [JMH]. Note that the benchmark result from IDE
36  might not be as reliable as the above approaches and is generally not recommended.
37
38[JMH]: http://openjdk.java.net/projects/code-tools/jmh/
39