Add throughput benchmark for petclinic load testing#11098
Add throughput benchmark for petclinic load testing#11098
Conversation
Adds a new benchmark category under benchmark/memory/petclinic/ that measures tracer throughput overhead across decreasing heap sizes using spring-petclinic 3.3.0 and JMeter. Based on Doug's methodology for evaluating memory overhead of the Java tracer agent. The script auto-downloads JMeter and builds petclinic, iterates over configurable heap sizes (default: 256/192/128/96/80/64 MiB), runs each with and without the agent, and outputs a comparison table with throughput delta. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
I think it is more important to see the difference of dd-java-agent with and without the change. Is that something we can add? |
BenchmarksStartupParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 59 metrics, 12 unstable metrics. Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.059 s) : 0, 1058565
Total [baseline] (8.841 s) : 0, 8841421
Agent [candidate] (1.063 s) : 0, 1062830
Total [candidate] (8.861 s) : 0, 8861391
section iast
Agent [baseline] (1.222 s) : 0, 1221718
Total [baseline] (9.587 s) : 0, 9587037
Agent [candidate] (1.222 s) : 0, 1221562
Total [candidate] (9.573 s) : 0, 9573381
gantt
title insecure-bank - break down per module: candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.236 ms) : 0, 1236
crashtracking [candidate] (1.24 ms) : 0, 1240
BytebuddyAgent [baseline] (632.428 ms) : 0, 632428
BytebuddyAgent [candidate] (637.12 ms) : 0, 637120
AgentMeter [baseline] (29.45 ms) : 0, 29450
AgentMeter [candidate] (29.717 ms) : 0, 29717
GlobalTracer [baseline] (249.268 ms) : 0, 249268
GlobalTracer [candidate] (250.218 ms) : 0, 250218
AppSec [baseline] (32.187 ms) : 0, 32187
AppSec [candidate] (32.32 ms) : 0, 32320
Debugger [baseline] (59.334 ms) : 0, 59334
Debugger [candidate] (59.364 ms) : 0, 59364
Remote Config [baseline] (605.919 µs) : 0, 606
Remote Config [candidate] (956.552 µs) : 0, 957
Telemetry [baseline] (8.092 ms) : 0, 8092
Telemetry [candidate] (8.09 ms) : 0, 8090
Flare Poller [baseline] (9.811 ms) : 0, 9811
Flare Poller [candidate] (7.48 ms) : 0, 7480
section iast
crashtracking [baseline] (1.238 ms) : 0, 1238
crashtracking [candidate] (1.227 ms) : 0, 1227
BytebuddyAgent [baseline] (799.44 ms) : 0, 799440
BytebuddyAgent [candidate] (799.159 ms) : 0, 799159
AgentMeter [baseline] (11.365 ms) : 0, 11365
AgentMeter [candidate] (11.355 ms) : 0, 11355
GlobalTracer [baseline] (238.61 ms) : 0, 238610
GlobalTracer [candidate] (238.92 ms) : 0, 238920
AppSec [baseline] (30.187 ms) : 0, 30187
AppSec [candidate] (28.69 ms) : 0, 28690
Debugger [baseline] (61.955 ms) : 0, 61955
Debugger [candidate] (63.231 ms) : 0, 63231
Remote Config [baseline] (536.609 µs) : 0, 537
Remote Config [candidate] (1.136 ms) : 0, 1136
Telemetry [baseline] (12.602 ms) : 0, 12602
Telemetry [candidate] (12.226 ms) : 0, 12226
Flare Poller [baseline] (3.592 ms) : 0, 3592
Flare Poller [candidate] (3.391 ms) : 0, 3391
IAST [baseline] (25.788 ms) : 0, 25788
IAST [candidate] (25.904 ms) : 0, 25904
Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.065 s) : 0, 1064885
Total [baseline] (11.048 s) : 0, 11048054
Agent [candidate] (1.054 s) : 0, 1053681
Total [candidate] (11.068 s) : 0, 11067791
section appsec
Agent [baseline] (1.257 s) : 0, 1257289
Total [baseline] (11.132 s) : 0, 11131814
Agent [candidate] (1.253 s) : 0, 1253073
Total [candidate] (11.105 s) : 0, 11104869
section iast
Agent [baseline] (1.224 s) : 0, 1224324
Total [baseline] (11.307 s) : 0, 11307190
Agent [candidate] (1.226 s) : 0, 1225748
Total [candidate] (11.338 s) : 0, 11338057
section profiling
Agent [baseline] (1.186 s) : 0, 1185927
Total [baseline] (11.006 s) : 0, 11005533
Agent [candidate] (1.186 s) : 0, 1185906
Total [candidate] (11.073 s) : 0, 11073065
gantt
title petclinic - break down per module: candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.255 ms) : 0, 1255
crashtracking [candidate] (1.226 ms) : 0, 1226
BytebuddyAgent [baseline] (637.272 ms) : 0, 637272
BytebuddyAgent [candidate] (631.021 ms) : 0, 631021
AgentMeter [baseline] (29.659 ms) : 0, 29659
AgentMeter [candidate] (29.481 ms) : 0, 29481
GlobalTracer [baseline] (250.117 ms) : 0, 250117
GlobalTracer [candidate] (248.703 ms) : 0, 248703
AppSec [baseline] (32.199 ms) : 0, 32199
AppSec [candidate] (31.997 ms) : 0, 31997
Debugger [baseline] (60.371 ms) : 0, 60371
Debugger [candidate] (59.906 ms) : 0, 59906
Remote Config [baseline] (600.001 µs) : 0, 600
Remote Config [candidate] (591.612 µs) : 0, 592
Telemetry [baseline] (8.126 ms) : 0, 8126
Telemetry [candidate] (8.026 ms) : 0, 8026
Flare Poller [baseline] (8.994 ms) : 0, 8994
Flare Poller [candidate] (6.64 ms) : 0, 6640
section appsec
crashtracking [baseline] (1.226 ms) : 0, 1226
crashtracking [candidate] (1.215 ms) : 0, 1215
BytebuddyAgent [baseline] (666.632 ms) : 0, 666632
BytebuddyAgent [candidate] (664.449 ms) : 0, 664449
AgentMeter [baseline] (12.193 ms) : 0, 12193
AgentMeter [candidate] (12.153 ms) : 0, 12153
GlobalTracer [baseline] (250.981 ms) : 0, 250981
GlobalTracer [candidate] (250.272 ms) : 0, 250272
AppSec [baseline] (185.751 ms) : 0, 185751
AppSec [candidate] (184.887 ms) : 0, 184887
Debugger [baseline] (66.249 ms) : 0, 66249
Debugger [candidate] (66.32 ms) : 0, 66320
Remote Config [baseline] (604.934 µs) : 0, 605
Remote Config [candidate] (592.358 µs) : 0, 592
Telemetry [baseline] (8.774 ms) : 0, 8774
Telemetry [candidate] (8.618 ms) : 0, 8618
Flare Poller [baseline] (3.641 ms) : 0, 3641
Flare Poller [candidate] (3.562 ms) : 0, 3562
IAST [baseline] (24.774 ms) : 0, 24774
IAST [candidate] (24.548 ms) : 0, 24548
section iast
crashtracking [baseline] (1.223 ms) : 0, 1223
crashtracking [candidate] (1.234 ms) : 0, 1234
BytebuddyAgent [baseline] (800.598 ms) : 0, 800598
BytebuddyAgent [candidate] (802.862 ms) : 0, 802862
AgentMeter [baseline] (11.424 ms) : 0, 11424
AgentMeter [candidate] (11.428 ms) : 0, 11428
GlobalTracer [baseline] (239.382 ms) : 0, 239382
GlobalTracer [candidate] (239.22 ms) : 0, 239220
AppSec [baseline] (32.64 ms) : 0, 32640
AppSec [candidate] (31.648 ms) : 0, 31648
Debugger [baseline] (59.153 ms) : 0, 59153
Debugger [candidate] (59.824 ms) : 0, 59824
Remote Config [baseline] (532.634 µs) : 0, 533
Remote Config [candidate] (1.096 ms) : 0, 1096
Telemetry [baseline] (13.624 ms) : 0, 13624
Telemetry [candidate] (12.846 ms) : 0, 12846
Flare Poller [baseline] (3.487 ms) : 0, 3487
Flare Poller [candidate] (3.469 ms) : 0, 3469
IAST [baseline] (25.871 ms) : 0, 25871
IAST [candidate] (25.758 ms) : 0, 25758
section profiling
crashtracking [baseline] (1.184 ms) : 0, 1184
crashtracking [candidate] (1.195 ms) : 0, 1195
BytebuddyAgent [baseline] (692.08 ms) : 0, 692080
BytebuddyAgent [candidate] (693.371 ms) : 0, 693371
AgentMeter [baseline] (9.161 ms) : 0, 9161
AgentMeter [candidate] (9.084 ms) : 0, 9084
GlobalTracer [baseline] (207.527 ms) : 0, 207527
GlobalTracer [candidate] (207.129 ms) : 0, 207129
AppSec [baseline] (32.598 ms) : 0, 32598
AppSec [candidate] (32.472 ms) : 0, 32472
Debugger [baseline] (65.648 ms) : 0, 65648
Debugger [candidate] (65.3 ms) : 0, 65300
Remote Config [baseline] (582.152 µs) : 0, 582
Remote Config [candidate] (564.828 µs) : 0, 565
Telemetry [baseline] (7.838 ms) : 0, 7838
Telemetry [candidate] (7.8 ms) : 0, 7800
Flare Poller [baseline] (3.537 ms) : 0, 3537
Flare Poller [candidate] (3.587 ms) : 0, 3587
ProfilingAgent [baseline] (94.124 ms) : 0, 94124
ProfilingAgent [candidate] (93.732 ms) : 0, 93732
Profiling [baseline] (94.684 ms) : 0, 94684
Profiling [candidate] (94.287 ms) : 0, 94287
LoadParameters
See matching parameters
SummaryFound 2 performance improvements and 0 performance regressions! Performance is the same for 18 metrics, 16 unstable metrics.
Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section baseline
no_agent (1.247 ms) : 1234, 1260
. : milestone, 1247,
iast (3.45 ms) : 3407, 3494
. : milestone, 3450,
iast_FULL (6.035 ms) : 5974, 6097
. : milestone, 6035,
iast_GLOBAL (3.736 ms) : 3671, 3800
. : milestone, 3736,
profiling (2.419 ms) : 2393, 2445
. : milestone, 2419,
tracing (1.906 ms) : 1890, 1923
. : milestone, 1906,
section candidate
no_agent (1.223 ms) : 1211, 1234
. : milestone, 1223,
iast (3.34 ms) : 3298, 3382
. : milestone, 3340,
iast_FULL (5.997 ms) : 5935, 6059
. : milestone, 5997,
iast_GLOBAL (3.625 ms) : 3571, 3679
. : milestone, 3625,
profiling (2.087 ms) : 2068, 2106
. : milestone, 2087,
tracing (1.919 ms) : 1901, 1938
. : milestone, 1919,
Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section baseline
no_agent (18.359 ms) : 18170, 18549
. : milestone, 18359,
appsec (20.238 ms) : 20030, 20447
. : milestone, 20238,
code_origins (17.965 ms) : 17788, 18142
. : milestone, 17965,
iast (19.056 ms) : 18868, 19244
. : milestone, 19056,
profiling (18.157 ms) : 17981, 18332
. : milestone, 18157,
tracing (17.614 ms) : 17442, 17785
. : milestone, 17614,
section candidate
no_agent (18.379 ms) : 18194, 18564
. : milestone, 18379,
appsec (19.217 ms) : 19024, 19411
. : milestone, 19217,
code_origins (17.973 ms) : 17795, 18151
. : milestone, 17973,
iast (19.53 ms) : 19334, 19727
. : milestone, 19530,
profiling (18.542 ms) : 18359, 18724
. : milestone, 18542,
tracing (17.807 ms) : 17634, 17981
. : milestone, 17807,
DacapoParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 11 metrics, 1 unstable metrics. Execution time for tomcatgantt
title tomcat - execution time [CI 0.99] : candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section baseline
no_agent (1.488 ms) : 1477, 1500
. : milestone, 1488,
appsec (2.539 ms) : 2484, 2593
. : milestone, 2539,
iast (2.268 ms) : 2199, 2337
. : milestone, 2268,
iast_GLOBAL (2.317 ms) : 2247, 2386
. : milestone, 2317,
profiling (2.099 ms) : 2044, 2154
. : milestone, 2099,
tracing (2.077 ms) : 2023, 2130
. : milestone, 2077,
section candidate
no_agent (1.487 ms) : 1476, 1499
. : milestone, 1487,
appsec (3.846 ms) : 3622, 4069
. : milestone, 3846,
iast (2.272 ms) : 2202, 2341
. : milestone, 2272,
iast_GLOBAL (2.308 ms) : 2239, 2377
. : milestone, 2308,
profiling (2.098 ms) : 2043, 2153
. : milestone, 2098,
tracing (2.084 ms) : 2030, 2137
. : milestone, 2084,
Execution time for biojavagantt
title biojava - execution time [CI 0.99] : candidate=1.62.0-SNAPSHOT~f8fc1df1dd, baseline=1.62.0-SNAPSHOT~140eee9add
dateFormat X
axisFormat %s
section baseline
no_agent (15.179 s) : 15179000, 15179000
. : milestone, 15179000,
appsec (14.794 s) : 14794000, 14794000
. : milestone, 14794000,
iast (18.214 s) : 18214000, 18214000
. : milestone, 18214000,
iast_GLOBAL (18.157 s) : 18157000, 18157000
. : milestone, 18157000,
profiling (14.948 s) : 14948000, 14948000
. : milestone, 14948000,
tracing (14.742 s) : 14742000, 14742000
. : milestone, 14742000,
section candidate
no_agent (15.485 s) : 15485000, 15485000
. : milestone, 15485000,
appsec (15.083 s) : 15083000, 15083000
. : milestone, 15083000,
iast (18.449 s) : 18449000, 18449000
. : milestone, 18449000,
iast_GLOBAL (17.892 s) : 17892000, 17892000
. : milestone, 17892000,
profiling (15.085 s) : 15085000, 15085000
. : milestone, 15085000,
tracing (14.919 s) : 14919000, 14919000
. : milestone, 14919000,
|
| @@ -0,0 +1,2 @@ | |||
| tools/ | |||
There was a problem hiding this comment.
Placing these in a "memory" folder seems off to me.
The intent of running at multiple memory settings is to simulate how the application behaves under load relative to available resources, so I don't think of this as a memory benchmark.
There was a problem hiding this comment.
Moved it to benchmark/throughput/petclinic/.
Address review feedback: the benchmark measures throughput under load at varying resource constraints, not memory specifically. Renamed directory and updated all references. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
You can do that today by running twice with different ./run.sh --agent /path/to/dd-java-agent-1.61.0.jar --output ./results/before
./run.sh --agent /path/to/dd-java-agent-SNAPSHOT.jar --output ./results/after --skip-baselineI could also add a |
What Does This Do
Adds a new throughput benchmark under
benchmark/throughput/petclinic/that measures tracer throughput overhead under load at varying heap sizes using spring-petclinic 3.3.0-SNAPSHOT and JMeter.Motivation
Automates the manual process of running petclinic at various heap sizes (256m → 64m) with and without the agent, measuring stabilized throughput, and comparing the delta.
The script:
7034d17)GET /owners/3), captures throughput from the measurement window (discarding warmup)Example output from a local run (Zulu 17, Apple Silicon):
Differences from the original manual benchmark
tasksetto pin server processes to specific cores. This script does not pin, so results are noisier due to scheduling jitter.--skip-baselineand different--agentpaths.Additional Notes
--jfrflag for JFR profiling during measurement--skip-baselinefor comparing multiple candidate builds without re-running baseline--agent-optsfor testing with specific features disabledtools/andresults/directories are gitignoredtag: ai generated
Contributor Checklist
type:and (comp:orinst:) labelsclose,fix, or linking keywords🤖 Generated with Claude Code