Skip to content

Comments

Fix method parameters JVM bug#10521

Open
jpbempel wants to merge 8 commits intomasterfrom
jpbempel/fix-method-parameters
Open

Fix method parameters JVM bug#10521
jpbempel wants to merge 8 commits intomasterfrom
jpbempel/fix-method-parameters

Conversation

@jpbempel
Copy link
Member

@jpbempel jpbempel commented Feb 4, 2026

What Does This Do

Prevent classfiles with Method Parameters attribute (javac -parameters) to be (re)transformed when on JDK < 19. Spring 6+ or SpringBoot3+ rely exclusively on method parameters to get param name and if the attribute is not present throw an exception and returns 500 on endpoints.
see OpenJDK bug JDK-8240908.
we are scanning method with at least on parameter to detect if the class was compiled with method parameters attribute and if the JDK is < 19 we prevent instrumentation to happen.
Even at load time we prevent it because we need to call retransform to remove instrumentation. Therefore the attribute can be strip at that time.
Then we are trying to scan for a specific Spring6+ only class. If the class is not present we are considering this is
safe to retransform as those versions of Spring are not relying on this.
Note: because Scala compiler always emits Method Parameters attribute, probe cannot work on scala if running on JDK < 19

Motivation

Additional Notes

OpenJDK bug

Contributor Checklist

Jira ticket: DEBUG-5131

@jpbempel jpbempel requested a review from a team as a code owner February 4, 2026 11:47
@jpbempel jpbempel requested review from andreimatei and removed request for a team February 4, 2026 11:47
@jpbempel jpbempel added the comp: debugger Dynamic Instrumentation label Feb 4, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Feb 4, 2026

Hi! 👋 Thanks for your pull request! 🎉

To help us review it, please make sure to:

  • Add at least one type, and one component or instrumentation label to the pull request

If you need help, please check our contributing guidelines.

@jpbempel jpbempel added the type: bug Bug report and fix label Feb 4, 2026
@pr-commenter
Copy link

pr-commenter bot commented Feb 4, 2026

Debugger benchmarks

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
ci_job_date 1771611386 1771611732
end_time 2026-02-20T18:17:46 2026-02-20T18:23:32
git_branch master jpbempel/fix-method-parameters
git_commit_sha 9553001 5ba371e
start_time 2026-02-20T18:16:27 2026-02-20T18:22:13
See matching parameters
Baseline Candidate
ci_job_id 1444089993 1444089993
ci_pipeline_id 97931697 97931697
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
git_commit_date 1771610439 1771610439

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 9 metrics, 6 unstable metrics.

See unchanged results
scenario Δ mean agg_http_req_duration_min Δ mean agg_http_req_duration_p50 Δ mean agg_http_req_duration_p75 Δ mean agg_http_req_duration_p99 Δ mean throughput
scenario:noprobe unstable
[-37.684µs; +25.026µs] or [-13.371%; +8.879%]
unstable
[-51.901µs; +37.237µs] or [-16.066%; +11.527%]
unstable
[-65.537µs; +46.466µs] or [-19.336%; +13.709%]
unstable
[-18.512µs; +215.733µs] or [-2.090%; +24.359%]
same
scenario:basic unsure
[-8.715µs; -2.065µs] or [-3.471%; -0.822%]
same same unstable
[-11.783µs; +190.100µs] or [-1.603%; +25.868%]
unstable
[-87.116op/s; +229.363op/s] or [-3.310%; +8.716%]
scenario:loop unsure
[-17.395µs; -10.713µs] or [-0.196%; -0.121%]
unsure
[-22.104µs; -12.556µs] or [-0.246%; -0.140%]
unsure
[-21.890µs; -11.508µs] or [-0.243%; -0.128%]
unsure
[-109.588µs; -15.778µs] or [-1.195%; -0.172%]
same
Request duration reports for reports
gantt
    title reports - request duration [CI 0.99] : candidate=None, baseline=None
    dateFormat X
    axisFormat %s
section baseline
noprobe (323.054 µs) : 273, 373
.   : milestone, 323,
basic (279.718 µs) : 273, 286
.   : milestone, 280,
loop (8.969 ms) : 8965, 8974
.   : milestone, 8969,
section candidate
noprobe (315.722 µs) : 283, 349
.   : milestone, 316,
basic (274.309 µs) : 268, 281
.   : milestone, 274,
loop (8.952 ms) : 8948, 8956
.   : milestone, 8952,
Loading
  • baseline results
Scenario Request median duration [CI 0.99]
noprobe 323.054 µs [273.034 µs, 373.074 µs]
basic 279.718 µs [273.03 µs, 286.406 µs]
loop 8.969 ms [8.965 ms, 8.974 ms]
  • candidate results
Scenario Request median duration [CI 0.99]
noprobe 315.722 µs [282.546 µs, 348.898 µs]
basic 274.309 µs [267.888 µs, 280.729 µs]
loop 8.952 ms [8.948 ms, 8.956 ms]

@pr-commenter
Copy link

pr-commenter bot commented Feb 4, 2026

Benchmarks

Startup

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master jpbempel/fix-method-parameters
git_commit_date 1771530866 1771610439
git_commit_sha af8b844 5ba371e
release_version 1.60.0-SNAPSHOT~af8b84438c 1.60.0-SNAPSHOT~5ba371eb8e
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1771612676 1771612676
ci_job_id 1444089986 1444089986
ci_pipeline_id 97931697 97931697
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
kernel_version Linux runner-zfyrx7zua-project-304-concurrent-1-os9vux9q 6.8.0-1031-aws #33~22.04.1-Ubuntu SMP Thu Jun 26 14:22:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Linux runner-zfyrx7zua-project-304-concurrent-1-os9vux9q 6.8.0-1031-aws #33~22.04.1-Ubuntu SMP Thu Jun 26 14:22:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
module Agent Agent
parent None None

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 60 metrics, 11 unstable metrics.

Startup time reports for petclinic
gantt
    title petclinic - global startup overhead: candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.064 s) : 0, 1063929
Total [baseline] (10.887 s) : 0, 10886846
Agent [candidate] (1.08 s) : 0, 1080421
Total [candidate] (10.907 s) : 0, 10906635
section appsec
Agent [baseline] (1.241 s) : 0, 1240556
Total [baseline] (11.038 s) : 0, 11038171
Agent [candidate] (1.24 s) : 0, 1240035
Total [candidate] (11.078 s) : 0, 11077503
section iast
Agent [baseline] (1.244 s) : 0, 1244376
Total [baseline] (11.292 s) : 0, 11291646
Agent [candidate] (1.233 s) : 0, 1233389
Total [candidate] (11.26 s) : 0, 11259674
section profiling
Agent [baseline] (1.191 s) : 0, 1190895
Total [baseline] (10.891 s) : 0, 10890710
Agent [candidate] (1.193 s) : 0, 1192607
Total [candidate] (10.965 s) : 0, 10964843
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.064 s -
Agent appsec 1.241 s 176.627 ms (16.6%)
Agent iast 1.244 s 180.446 ms (17.0%)
Agent profiling 1.191 s 126.966 ms (11.9%)
Total tracing 10.887 s -
Total appsec 11.038 s 151.324 ms (1.4%)
Total iast 11.292 s 404.8 ms (3.7%)
Total profiling 10.891 s 3.863 ms (0.0%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.08 s -
Agent appsec 1.24 s 159.614 ms (14.8%)
Agent iast 1.233 s 152.967 ms (14.2%)
Agent profiling 1.193 s 112.186 ms (10.4%)
Total tracing 10.907 s -
Total appsec 11.078 s 170.868 ms (1.6%)
Total iast 11.26 s 353.038 ms (3.2%)
Total profiling 10.965 s 58.208 ms (0.5%)
gantt
    title petclinic - break down per module: candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c

    dateFormat X
    axisFormat %s
section tracing
crashtracking [baseline] (1.192 ms) : 0, 1192
crashtracking [candidate] (1.206 ms) : 0, 1206
BytebuddyAgent [baseline] (627.287 ms) : 0, 627287
BytebuddyAgent [candidate] (636.904 ms) : 0, 636904
AgentMeter [baseline] (29.059 ms) : 0, 29059
AgentMeter [candidate] (29.513 ms) : 0, 29513
GlobalTracer [baseline] (257.29 ms) : 0, 257290
GlobalTracer [candidate] (260.515 ms) : 0, 260515
AppSec [baseline] (32.986 ms) : 0, 32986
AppSec [candidate] (33.63 ms) : 0, 33630
Debugger [baseline] (64.955 ms) : 0, 64955
Debugger [candidate] (66.297 ms) : 0, 66297
Remote Config [baseline] (632.392 µs) : 0, 632
Remote Config [candidate] (623.461 µs) : 0, 623
Telemetry [baseline] (9.909 ms) : 0, 9909
Telemetry [candidate] (9.206 ms) : 0, 9206
Flare Poller [baseline] (4.573 ms) : 0, 4573
Flare Poller [candidate] (6.215 ms) : 0, 6215
section appsec
crashtracking [baseline] (1.184 ms) : 0, 1184
crashtracking [candidate] (1.193 ms) : 0, 1193
BytebuddyAgent [baseline] (659.213 ms) : 0, 659213
BytebuddyAgent [candidate] (658.679 ms) : 0, 658679
AgentMeter [baseline] (12.025 ms) : 0, 12025
AgentMeter [candidate] (12.006 ms) : 0, 12006
GlobalTracer [baseline] (258.97 ms) : 0, 258970
GlobalTracer [candidate] (258.374 ms) : 0, 258374
IAST [baseline] (25.481 ms) : 0, 25481
IAST [candidate] (25.368 ms) : 0, 25368
AppSec [baseline] (168.774 ms) : 0, 168774
AppSec [candidate] (167.864 ms) : 0, 167864
Debugger [baseline] (65.341 ms) : 0, 65341
Debugger [candidate] (66.663 ms) : 0, 66663
Remote Config [baseline] (626.383 µs) : 0, 626
Remote Config [candidate] (639.257 µs) : 0, 639
Telemetry [baseline] (9.19 ms) : 0, 9190
Telemetry [candidate] (9.384 ms) : 0, 9384
Flare Poller [baseline] (3.634 ms) : 0, 3634
Flare Poller [candidate] (3.737 ms) : 0, 3737
section iast
crashtracking [baseline] (1.212 ms) : 0, 1212
crashtracking [candidate] (1.193 ms) : 0, 1193
BytebuddyAgent [baseline] (804.153 ms) : 0, 804153
BytebuddyAgent [candidate] (796.206 ms) : 0, 796206
AgentMeter [baseline] (11.617 ms) : 0, 11617
AgentMeter [candidate] (11.316 ms) : 0, 11316
GlobalTracer [baseline] (249.771 ms) : 0, 249771
GlobalTracer [candidate] (248.171 ms) : 0, 248171
IAST [baseline] (27.337 ms) : 0, 27337
IAST [candidate] (27.01 ms) : 0, 27010
AppSec [baseline] (35.247 ms) : 0, 35247
AppSec [candidate] (34.939 ms) : 0, 34939
Debugger [baseline] (66.099 ms) : 0, 66099
Debugger [candidate] (65.911 ms) : 0, 65911
Remote Config [baseline] (534.5 µs) : 0, 534
Remote Config [candidate] (541.121 µs) : 0, 541
Telemetry [baseline] (8.658 ms) : 0, 8658
Telemetry [candidate] (8.575 ms) : 0, 8575
Flare Poller [baseline] (3.468 ms) : 0, 3468
Flare Poller [candidate] (3.481 ms) : 0, 3481
section profiling
crashtracking [baseline] (1.178 ms) : 0, 1178
crashtracking [candidate] (1.184 ms) : 0, 1184
BytebuddyAgent [baseline] (680.681 ms) : 0, 680681
BytebuddyAgent [candidate] (682.711 ms) : 0, 682711
AgentMeter [baseline] (8.519 ms) : 0, 8519
AgentMeter [candidate] (8.546 ms) : 0, 8546
GlobalTracer [baseline] (215.736 ms) : 0, 215736
GlobalTracer [candidate] (216.023 ms) : 0, 216023
AppSec [baseline] (32.689 ms) : 0, 32689
AppSec [candidate] (32.559 ms) : 0, 32559
Debugger [baseline] (67.97 ms) : 0, 67970
Debugger [candidate] (67.465 ms) : 0, 67465
Remote Config [baseline] (644.845 µs) : 0, 645
Remote Config [candidate] (663.52 µs) : 0, 664
Telemetry [baseline] (9.046 ms) : 0, 9046
Telemetry [candidate] (9.057 ms) : 0, 9057
Flare Poller [baseline] (3.77 ms) : 0, 3770
Flare Poller [candidate] (3.739 ms) : 0, 3739
ProfilingAgent [baseline] (100.111 ms) : 0, 100111
ProfilingAgent [candidate] (99.798 ms) : 0, 99798
Profiling [baseline] (100.719 ms) : 0, 100719
Profiling [candidate] (100.368 ms) : 0, 100368
Loading
Startup time reports for insecure-bank
gantt
    title insecure-bank - global startup overhead: candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.065 s) : 0, 1064735
Total [baseline] (8.766 s) : 0, 8766416
Agent [candidate] (1.067 s) : 0, 1066887
Total [candidate] (8.769 s) : 0, 8769485
section iast
Agent [baseline] (1.235 s) : 0, 1235016
Total [baseline] (9.37 s) : 0, 9369523
Agent [candidate] (1.232 s) : 0, 1232345
Total [candidate] (9.372 s) : 0, 9371843
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.065 s -
Agent iast 1.235 s 170.281 ms (16.0%)
Total tracing 8.766 s -
Total iast 9.37 s 603.106 ms (6.9%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.067 s -
Agent iast 1.232 s 165.458 ms (15.5%)
Total tracing 8.769 s -
Total iast 9.372 s 602.358 ms (6.9%)
gantt
    title insecure-bank - break down per module: candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c

    dateFormat X
    axisFormat %s
section tracing
crashtracking [baseline] (1.2 ms) : 0, 1200
crashtracking [candidate] (1.231 ms) : 0, 1231
BytebuddyAgent [baseline] (628.073 ms) : 0, 628073
BytebuddyAgent [candidate] (627.74 ms) : 0, 627740
AgentMeter [baseline] (29.142 ms) : 0, 29142
AgentMeter [candidate] (29.063 ms) : 0, 29063
GlobalTracer [baseline] (257.499 ms) : 0, 257499
GlobalTracer [candidate] (259.267 ms) : 0, 259267
AppSec [baseline] (32.997 ms) : 0, 32997
AppSec [candidate] (33.398 ms) : 0, 33398
Debugger [baseline] (65.336 ms) : 0, 65336
Debugger [candidate] (64.096 ms) : 0, 64096
Remote Config [baseline] (636.234 µs) : 0, 636
Remote Config [candidate] (611.931 µs) : 0, 612
Telemetry [baseline] (9.093 ms) : 0, 9093
Telemetry [candidate] (10.692 ms) : 0, 10692
Flare Poller [baseline] (4.514 ms) : 0, 4514
Flare Poller [candidate] (4.664 ms) : 0, 4664
section iast
crashtracking [baseline] (1.214 ms) : 0, 1214
crashtracking [candidate] (1.2 ms) : 0, 1200
BytebuddyAgent [baseline] (799.241 ms) : 0, 799241
BytebuddyAgent [candidate] (796.263 ms) : 0, 796263
AgentMeter [baseline] (11.249 ms) : 0, 11249
AgentMeter [candidate] (11.36 ms) : 0, 11360
GlobalTracer [baseline] (247.28 ms) : 0, 247280
GlobalTracer [candidate] (248.054 ms) : 0, 248054
IAST [baseline] (26.945 ms) : 0, 26945
IAST [candidate] (27.151 ms) : 0, 27151
AppSec [baseline] (33.954 ms) : 0, 33954
AppSec [candidate] (34.042 ms) : 0, 34042
Debugger [baseline] (66.183 ms) : 0, 66183
Debugger [candidate] (65.557 ms) : 0, 65557
Remote Config [baseline] (556.637 µs) : 0, 557
Remote Config [candidate] (532.111 µs) : 0, 532
Telemetry [baseline] (8.701 ms) : 0, 8701
Telemetry [candidate] (8.568 ms) : 0, 8568
Flare Poller [baseline] (3.502 ms) : 0, 3502
Flare Poller [candidate] (3.475 ms) : 0, 3475
Loading

Load

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master jpbempel/fix-method-parameters
git_commit_date 1771530866 1771610439
git_commit_sha af8b844 5ba371e
release_version 1.60.0-SNAPSHOT~af8b84438c 1.60.0-SNAPSHOT~5ba371eb8e
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1771613085 1771613085
ci_job_id 1444089987 1444089987
ci_pipeline_id 97931697 97931697
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
kernel_version Linux runner-zfyrx7zua-project-304-concurrent-0-qnewz3f5 6.8.0-1031-aws #33~22.04.1-Ubuntu SMP Thu Jun 26 14:22:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Linux runner-zfyrx7zua-project-304-concurrent-0-qnewz3f5 6.8.0-1031-aws #33~22.04.1-Ubuntu SMP Thu Jun 26 14:22:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 20 metrics, 16 unstable metrics.

Request duration reports for insecure-bank
gantt
    title insecure-bank - request duration [CI 0.99] : candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.173 ms) : 1161, 1184
.   : milestone, 1173,
iast (3.301 ms) : 3252, 3350
.   : milestone, 3301,
iast_FULL (5.663 ms) : 5608, 5718
.   : milestone, 5663,
iast_GLOBAL (3.56 ms) : 3498, 3621
.   : milestone, 3560,
profiling (2.22 ms) : 2199, 2241
.   : milestone, 2220,
tracing (1.79 ms) : 1775, 1805
.   : milestone, 1790,
section candidate
no_agent (1.198 ms) : 1186, 1211
.   : milestone, 1198,
iast (3.202 ms) : 3160, 3245
.   : milestone, 3202,
iast_FULL (5.753 ms) : 5694, 5811
.   : milestone, 5753,
iast_GLOBAL (3.558 ms) : 3506, 3609
.   : milestone, 3558,
profiling (2.118 ms) : 2099, 2137
.   : milestone, 2118,
tracing (1.829 ms) : 1813, 1844
.   : milestone, 1829,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.173 ms [1.161 ms, 1.184 ms] -
iast 3.301 ms [3.252 ms, 3.35 ms] 2.128 ms (181.5%)
iast_FULL 5.663 ms [5.608 ms, 5.718 ms] 4.49 ms (382.9%)
iast_GLOBAL 3.56 ms [3.498 ms, 3.621 ms] 2.387 ms (203.6%)
profiling 2.22 ms [2.199 ms, 2.241 ms] 1.047 ms (89.3%)
tracing 1.79 ms [1.775 ms, 1.805 ms] 617.465 µs (52.7%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.198 ms [1.186 ms, 1.211 ms] -
iast 3.202 ms [3.16 ms, 3.245 ms] 2.004 ms (167.2%)
iast_FULL 5.753 ms [5.694 ms, 5.811 ms] 4.554 ms (380.0%)
iast_GLOBAL 3.558 ms [3.506 ms, 3.609 ms] 2.359 ms (196.9%)
profiling 2.118 ms [2.099 ms, 2.137 ms] 919.956 µs (76.8%)
tracing 1.829 ms [1.813 ms, 1.844 ms] 630.12 µs (52.6%)
Request duration reports for petclinic
gantt
    title petclinic - request duration [CI 0.99] : candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c
    dateFormat X
    axisFormat %s
section baseline
no_agent (18.973 ms) : 18777, 19169
.   : milestone, 18973,
appsec (18.458 ms) : 18271, 18646
.   : milestone, 18458,
code_origins (17.627 ms) : 17452, 17802
.   : milestone, 17627,
iast (17.731 ms) : 17558, 17904
.   : milestone, 17731,
profiling (18.468 ms) : 18285, 18651
.   : milestone, 18468,
tracing (17.878 ms) : 17700, 18056
.   : milestone, 17878,
section candidate
no_agent (19.079 ms) : 18881, 19277
.   : milestone, 19079,
appsec (18.594 ms) : 18407, 18781
.   : milestone, 18594,
code_origins (17.345 ms) : 17175, 17515
.   : milestone, 17345,
iast (17.924 ms) : 17745, 18103
.   : milestone, 17924,
profiling (18.313 ms) : 18132, 18495
.   : milestone, 18313,
tracing (17.33 ms) : 17161, 17499
.   : milestone, 17330,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 18.973 ms [18.777 ms, 19.169 ms] -
appsec 18.458 ms [18.271 ms, 18.646 ms] -514.558 µs (-2.7%)
code_origins 17.627 ms [17.452 ms, 17.802 ms] -1.346 ms (-7.1%)
iast 17.731 ms [17.558 ms, 17.904 ms] -1.242 ms (-6.5%)
profiling 18.468 ms [18.285 ms, 18.651 ms] -504.315 µs (-2.7%)
tracing 17.878 ms [17.7 ms, 18.056 ms] -1.095 ms (-5.8%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 19.079 ms [18.881 ms, 19.277 ms] -
appsec 18.594 ms [18.407 ms, 18.781 ms] -484.858 µs (-2.5%)
code_origins 17.345 ms [17.175 ms, 17.515 ms] -1.734 ms (-9.1%)
iast 17.924 ms [17.745 ms, 18.103 ms] -1.155 ms (-6.1%)
profiling 18.313 ms [18.132 ms, 18.495 ms] -765.467 µs (-4.0%)
tracing 17.33 ms [17.161 ms, 17.499 ms] -1.749 ms (-9.2%)

Dacapo

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master jpbempel/fix-method-parameters
git_commit_date 1771530866 1771610439
git_commit_sha af8b844 5ba371e
release_version 1.60.0-SNAPSHOT~af8b84438c 1.60.0-SNAPSHOT~5ba371eb8e
See matching parameters
Baseline Candidate
application biojava biojava
ci_job_date 1771612916 1771612916
ci_job_id 1444089988 1444089988
ci_pipeline_id 97931697 97931697
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
kernel_version Linux runner-zfyrx7zua-project-304-concurrent-2-3mbqc235 6.8.0-1031-aws #33~22.04.1-Ubuntu SMP Thu Jun 26 14:22:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux Linux runner-zfyrx7zua-project-304-concurrent-2-3mbqc235 6.8.0-1031-aws #33~22.04.1-Ubuntu SMP Thu Jun 26 14:22:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 11 metrics, 1 unstable metrics.

Execution time for tomcat
gantt
    title tomcat - execution time [CI 0.99] : candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.476 ms) : 1465, 1488
.   : milestone, 1476,
appsec (3.796 ms) : 3574, 4018
.   : milestone, 3796,
iast (2.245 ms) : 2176, 2314
.   : milestone, 2245,
iast_GLOBAL (2.301 ms) : 2232, 2371
.   : milestone, 2301,
profiling (2.095 ms) : 2039, 2151
.   : milestone, 2095,
tracing (2.053 ms) : 2000, 2106
.   : milestone, 2053,
section candidate
no_agent (1.475 ms) : 1464, 1487
.   : milestone, 1475,
appsec (3.721 ms) : 3504, 3937
.   : milestone, 3721,
iast (2.257 ms) : 2188, 2326
.   : milestone, 2257,
iast_GLOBAL (2.289 ms) : 2220, 2358
.   : milestone, 2289,
profiling (2.084 ms) : 2029, 2138
.   : milestone, 2084,
tracing (2.066 ms) : 2012, 2119
.   : milestone, 2066,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.476 ms [1.465 ms, 1.488 ms] -
appsec 3.796 ms [3.574 ms, 4.018 ms] 2.32 ms (157.1%)
iast 2.245 ms [2.176 ms, 2.314 ms] 768.807 µs (52.1%)
iast_GLOBAL 2.301 ms [2.232 ms, 2.371 ms] 825.182 µs (55.9%)
profiling 2.095 ms [2.039 ms, 2.151 ms] 618.99 µs (41.9%)
tracing 2.053 ms [2.0 ms, 2.106 ms] 577.104 µs (39.1%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.475 ms [1.464 ms, 1.487 ms] -
appsec 3.721 ms [3.504 ms, 3.937 ms] 2.246 ms (152.2%)
iast 2.257 ms [2.188 ms, 2.326 ms] 781.697 µs (53.0%)
iast_GLOBAL 2.289 ms [2.22 ms, 2.358 ms] 813.599 µs (55.2%)
profiling 2.084 ms [2.029 ms, 2.138 ms] 608.72 µs (41.3%)
tracing 2.066 ms [2.012 ms, 2.119 ms] 590.648 µs (40.0%)
Execution time for biojava
gantt
    title biojava - execution time [CI 0.99] : candidate=1.60.0-SNAPSHOT~5ba371eb8e, baseline=1.60.0-SNAPSHOT~af8b84438c
    dateFormat X
    axisFormat %s
section baseline
no_agent (14.998 s) : 14998000, 14998000
.   : milestone, 14998000,
appsec (14.752 s) : 14752000, 14752000
.   : milestone, 14752000,
iast (17.89 s) : 17890000, 17890000
.   : milestone, 17890000,
iast_GLOBAL (17.946 s) : 17946000, 17946000
.   : milestone, 17946000,
profiling (14.999 s) : 14999000, 14999000
.   : milestone, 14999000,
tracing (14.698 s) : 14698000, 14698000
.   : milestone, 14698000,
section candidate
no_agent (15.338 s) : 15338000, 15338000
.   : milestone, 15338000,
appsec (15.015 s) : 15015000, 15015000
.   : milestone, 15015000,
iast (18.19 s) : 18190000, 18190000
.   : milestone, 18190000,
iast_GLOBAL (17.812 s) : 17812000, 17812000
.   : milestone, 17812000,
profiling (14.832 s) : 14832000, 14832000
.   : milestone, 14832000,
tracing (14.729 s) : 14729000, 14729000
.   : milestone, 14729000,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 14.998 s [14.998 s, 14.998 s] -
appsec 14.752 s [14.752 s, 14.752 s] -246.0 ms (-1.6%)
iast 17.89 s [17.89 s, 17.89 s] 2.892 s (19.3%)
iast_GLOBAL 17.946 s [17.946 s, 17.946 s] 2.948 s (19.7%)
profiling 14.999 s [14.999 s, 14.999 s] 1.0 ms (0.0%)
tracing 14.698 s [14.698 s, 14.698 s] -300.0 ms (-2.0%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.338 s [15.338 s, 15.338 s] -
appsec 15.015 s [15.015 s, 15.015 s] -323.0 ms (-2.1%)
iast 18.19 s [18.19 s, 18.19 s] 2.852 s (18.6%)
iast_GLOBAL 17.812 s [17.812 s, 17.812 s] 2.474 s (16.1%)
profiling 14.832 s [14.832 s, 14.832 s] -506.0 ms (-3.3%)
tracing 14.729 s [14.729 s, 14.729 s] -609.0 ms (-4.0%)

Copy link
Contributor

@shatzi shatzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks great, but I think we need to a little more here

verify(probeStatusSink, times(1)).addError(probeIdCaptor.capture(), strCaptor.capture());
assertEquals(PROBE_ID.getId(), probeIdCaptor.getAllValues().get(0).getId());
assertEquals(
"Instrumentation fails for com.datadog.debugger.MyRecord1",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don’t like this error message. I’d prefer: "Instrumentation is not supported for class.method". This makes it clear to the user that nothing is wrong; it’s simply not supported, rather than implying something failed.

}
List<Class<?>> changedClasses =
finder.getAllLoadedChangedClasses(instrumentation.getAllLoadedClasses(), changes);
changedClasses = detectMethodParameters(changedClasses);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this means we filter the transformation for those probes, and therefore we don't report any probe status on those classes.

if this is the case, the UI would say error because no diagnostics where received. How complex would be to report a probe status on that one?

method.getName(),
parameters[0].getName());
// skip the class: compiled with -parameters
addClass = false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Idea: if getAllLoadedChangedClasses can return a list of probes per class, we can update their status and avoid rechecking the same class in the future. Since we already know probe-id X is blocked, we do not need to report changes for it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we bail out for entire applications? If one class was compiled using the -parameters argument is it worth rechecking ever again?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not all classes will be like this, you can have shared libraries or third-party libs that are not compiled with MethodParameters

@jpbempel jpbempel force-pushed the jpbempel/fix-method-parameters branch from 9acdfab to 4bfed3c Compare February 5, 2026 09:40
@tylfin
Copy link
Member

tylfin commented Feb 5, 2026

Can we add a release note with a breaking change to communicate to customers the added limitations here?

@kriegaex
Copy link

kriegaex commented Feb 13, 2026

Please note, that on the old JDK-8240908 ticket there has been recent activity for a JDK 17 backport, corresponding
OpenJDK PR 4265
has already been opened. So, in the future DataDog might be able securely to use retransformation again on JDK 17, if the update used is at least the version containing the backported fix from the PR. That would, however, require a runtime version check, which should be easy enough to implement. So, you probably want to create an issue to watch the OpenJDK ticket adjust this implementation as soon as an update with a backported fix is out.

See also my related Stack Overflow answer.

@jpbempel
Copy link
Member Author

Please note, that on the old JDK-8240908 ticket there has been recent activity for a JDK 17 backport, corresponding OpenJDK PR 4265 has already been opened. So, in the future DataDog might be able securely to use retransformation again on JDK 17, if the update used is at least the version containing the backported fix from the PR. That would, however, require a runtime version check, which should be easy enough to implement. So, you probably want to create an issue to watch the OpenJDK ticket adjust this implementation as soon as an update with a backported fix is out.

See also my related Stack Overflow answer.

Hi thanks for the comment. I have effectively triggered the backport triggered on the OpenJDK bug you mention.
if the backport is accepted and merged we will adapt the code to reflect this change

@desmond27
Copy link

Hi @jpbempel. I am the one who posted the query in the SO link @kriegaex commented about (SargentD on SO) and I've been trying to get the root cause of the error.

Sorry if this is the wrong place to ask this, but I was curious as to why this would behave flaky whenever controller methods with parameters are called? From what we've observed, the issue stops when we restart our server for a while but returns after an hour or so.

@jpbempel
Copy link
Member Author

Sorry if this is the wrong place to ask this, but I was curious as to why this would behave flaky whenever controller methods with parameters are called? From what we've observed, the issue stops when we restart our server for a while but returns after an hour or so.

@desmond27 no problem to discuss it here.
This bug is tricky on its manifestation because of the behavior of Spring: There is a cache of those method parameters.
So if a method/endpoint from a controller is already loaded and a request hits it, Spring framework will resolve those parameters correctly and cache them. later any retransformations happening won't affect as the cache will be used.
Now, is the endpoint is not yet it, resolution not done yet. we retransform the class, MethodParameters attribute from the class file is dropped. then a request hits the endpoint, Spring framework try to resolve the method parameters, not in the cache so rely on the attribute. Attribute not found leading to the IllegalArgumentException saying

Name for argument of type [XXX] not specified, and parameter name information not available via reflection. Ensure that the compiler uses the '-parameters' flag."

hope that helps to understand the issue

@desmond27
Copy link

desmond27 commented Feb 13, 2026

@jpbempel That seems plausible. Can we know which version of the Datadog agent was this introduced in (release date as well if possible since we use the https://dtdg.co/latest-java-tracer URL to get the agent)? We've been observing this since 23rd Jan. No issues were observed in the deployment before that time.

Edit: This is in the stack trace of the error, if that helps to identify:

datadog.trace.instrumentation.springweb6.HandlerMappingResourceNameFilter.doFilterInternal(HandlerMappingResourceNameFilter.java:57)

Edit 2: One more thing. If Live Debugger were to be enabled in Datadog, could that introduce this issue in an already running application?

@shatzi
Copy link
Contributor

shatzi commented Feb 13, 2026

@desmond27, Unfortunately, this issue has been part of Exception Replay since its introduction in 1.47.0. In newer tracer versions (1.54.0+), we started enabling the feature by default, which is why you likely began seeing this in January. You can opt out by going to the Error Tracking settings page and disabling Exception Replay for applications affected by this JDK bug until the patch is released.

Using Live Debugger on those classes or methods will show the same behavior until the JDK bug is fixed.

@kriegaex
Copy link

kriegaex commented Feb 14, 2026

Please bear with me, I am going to think aloud:

Spring 6+ or SpringBoot3+ rely exclusively on method parameters to get param name and if the attribute is not present throw an exception and returns 500 on endpoints

It is not quite that bad (i.e. exclusive), because instead of @PathVariable companyId, users can also add some boilerplate like @PathVariable("companyId") companyId, in which case a retransformed class would not cause any problems. Understandably, users dislike boilerplate and rather adjust their build to compile with -parameters. Then they blame any retransforming java agent - DataDog merely being one possibility - to break their application, which in a way is true, because without the agent everything runs smoothly. OTOH, it is quite a burden for java agents to know about and consider this corner case. There is no-one to blame, I am just describing the situation in more detail, if in the future anyone else reads this.

In any case, not just the release notes but the main documentation need to clearly describe this limitation and make users aware of the situation and when it can occur - certainly not when classes are transformed via redefineClasses during start-up, but rather when already loaded classes need to be retransformed for whatever reason. I never used DataDog before, maybe it has an option to remove instrumentation or to mix several types of instrumentation - but I am just guessing, I have no idea. (Update: I have just noticed the latest comments above, explaining how this can happen. Good to know for DD users.)

I also suggest to make retransformation optional in cases where we know that the JRE version in question does not support it. Some users might not need the lost parameter names, e.g. because they prefer to have DataDog monitor their Spring contollers at the cost of having to write @PathVariable("companyId") companyId. For some users, that is preferable to upgrading the JRE or to DataDog missing to report on some important methods. I am not sure if the default behaviour ought to be to skip or not to skip retransformation for methods with MethodParameters, but I think the user should have a choice to provide maximum flexibility and a conscious choice.

@jpbempel
Copy link
Member Author

It is not quite that bad (i.e. exclusive), because instead of @PathVariable companyId, users can also add some boilerplate like @PathVariable("companyId") companyId, in which case a retransformed class would not cause any problems. Understandably, users dislike boilerplate and rather adjust their build to compile with -parameters. Then they blame any retransforming java agent - DataDog merely being one possibility - to break their application, which in a way is true, because without the agent everything runs smoothly. OTOH, it is quite a burden for java agents to know about and consider this corner case. There is no-one to blame, I am just describing the situation in more detail, if in the future anyone else reads this.

The main problem is that it happens in the middle of nowhere while the application was running fine. Because of the nature of Exception Replay (triggers instrumentation using Instrumentation::retransformClasses when an exception occurs) + the caching system of Spring, this issue is quite random for the unaware users, and painful because the endpoints is rendered unusable. Yes there are workarounds but it requires to rewrite some parts of the code.

BTW retransforming classes is also hit by another annoying JVM bug on records JDK-8376185.

In any case, not just the release notes but the main documentation need to clearly describe this limitation and make users aware of the situation and when it can occur - certainly not when classes are transformed via redefineClasses during start-up, but rather when already loaded classes need to be retransformed for whatever reason. I never used DataDog before, maybe it has an option to remove instrumentation or to mix several types of instrumentation - but I am just guessing, I have no idea. (Update: I have just noticed the latest comments above, explaining how this can happen. Good to know for DD users.)

We will update the documentation accordingly. Note also that a backport of the patch for this bug is on going for JDK17 that is the minimum version required for Spring 6/Boot 3.

I also suggest to make retransformation optional in cases where we know that the JRE version in question does not support it. Some users might not need the lost parameter names, e.g. because they prefer to have DataDog monitor their Spring contollers at the cost of having to write @PathVariable("companyId") companyId. For some users, that is preferable to upgrading the JRE or to DataDog missing to report on some important methods. I am not sure if the default behaviour ought to be to skip or not to skip retransformation for methods with MethodParameters, but I think the user should have a choice to provide maximum flexibility and a conscious choice.

Retransformation is part of the products like Live Debugger, Dynamic Instrumentation, Exception Replay, Code Origin for Spans. Some are manually controlled, others are quite automatic. In any cases you can turn off explicitly all those products.

@kriegaex
Copy link

@jpbempel, yes, I know about the backport. I mentioned it in this thread myself in #10521 (comment).

Slightly off-topic: I think Spring could be improved to not throw exceptions but simply use the default JVM parameter names like arg0, arg1 and emit a warning rather than an exception. This is called defensive programming. It might be worth to open a Spring issue and also request backports for all still maintained versions.

@kriegaex
Copy link

kriegaex commented Feb 17, 2026

Retransformation is part of the products like Live Debugger, Dynamic Instrumentation, Exception Replay, Code Origin for Spans.

Just because as a non-user I got curious if I could reproduce the problem, I activated Live Debugger and Exception Replay and also made sure that one instrumented controller method also throws a random exception in 50% of the cases. The problem did not occur, as if I was unable to trigger retransformation. Can someone explain to me how I can make sure that retransformation gets triggered?

FWIW, my super simple reproducer (no DataDog, no agent on the command line, just plain Java) at Stack Overflow shows that retransformation indeed does cause the loss of method parameter names.

@jpbempel
Copy link
Member Author

Just because as a non-user I got curious if I could reproduce the problem, I activated Live Debugger and Exception Replay and also made sure that one instrumented controller method also throws a random exception in 50% of the cases. The problem did not occur, as if I was unable to trigger retransformation. Can someone explain to me how I can make sure that retransformation gets triggered?

With Live Debugger: just launch your spring app, not hitting yet an endpoint with parameters. Add a logpoint on that method, hit the endpoint with a request. you should have the exception.

@kriegaex
Copy link

kriegaex commented Feb 18, 2026

With Live Debugger: just launch your spring app, not hitting yet an endpoint with parameters. Add a logpoint on that method, hit the endpoint with a request. you should have the exception.

Brilliant, this works. Thank you so much, @jpbempel.

@desmond27, I think we now have the DataDog (DD) reproducer we wanted. The application works normally, then some dynamic instrumentation happens via retransformation, and despite having been compiled with -parameters, the application emits the error you have seen. I reproduced the issue with this sample repository based on your demo project, started with a local DD agent like this from my IDE:

image

Then, I added the DD logpoint:

image

Next, I hit the endpoint, seeing an error:

$ curl http://localhost:8080/api/v1/users/11
{"timestamp":"2026-02-18T00:42:35.225+00:00","status":500,"error":"Internal Server Error","path":"/api/v1/users/11"}

The corresponding Spring error log:

[dd.trace 2026-02-18 07:34:09:094 +0700] [dd-task-scheduler] INFO datadog.trace.agent.core.StatusLogger - DATADOG TRACER CONFIGURATION {"version":"1.59.0~7e1bb03bc3","os_name":"Windows 11","os_version":"10.0","architecture":"amd64","lang":"jvm","lang_version":"17.0.4.1","jvm_vendor":"Oracle Corporation","jvm_version":"17.0.4.1+1-LTS-2","java_class_version":"61.0","http_nonProxyHosts":"null","http_proxyHost":"null","enabled":true,"service":"spring-dd-repro","agent_url":"http://localhost:8126","agent_error":false,"debug":false,"trace_propagation_style_extract":["datadog","tracecontext","baggage"],"trace_propagation_style_inject":["datadog","tracecontext","baggage"],"analytics_enabled":false,"priority_sampling_enabled":true,"logs_correlation_enabled":true,"profiling_enabled":false,"remote_config_enabled":true,"debugger_enabled":false,"debugger_exception_enabled":false,"debugger_span_origin_enabled":false,"debugger_distributed_debugger_enabled":false,"appsec_enabled":"ENABLED_INACTIVE","rasp_enabled":true,"telemetry_enabled":true,"telemetry_dependency_collection_enabled":true,"telemetry_log_collection_enabled":true,"dd_version":"1.0.0","health_checks_enabled":true,"configuration_file":"no config file present","runtime_id":"fa2033ad-e872-42e5-9ed5-d6ac106d9ee3","logging_settings":{"showDateTime":true,"showLogName":true,"showThreadName":true,"defaultLogLevel":"INFO","embedException":false,"levelInBrackets":false,"dateTimeFormat":"'[dd.trace 'yyyy-MM-dd HH:mm:ss:SSS Z']'","logFile":"System.err","configurationFile":"simplelogger.properties","showShortLogName":false,"jsonEnabled":false,"warnLevelString":"WARN"},"cws_enabled":false,"cws_tls_refresh":5000,"datadog_profiler_enabled":false,"datadog_profiler_safe":false,"datadog_profiler_enabled_overridden":true,"data_streams_enabled":false,"app_logs_collection_enabled":false}
[dd.trace 2026-02-18 07:34:09:645 +0700] [dd-remote-config] INFO com.datadog.debugger.agent.DebuggerAgent - Starting Dynamic Instrumentation
[dd.trace 2026-02-18 07:34:09:647 +0700] [dd-remote-config] INFO com.datadog.debugger.agent.DebuggerAgent - Started Dynamic Instrumentation
[dd.trace 2026-02-18 07:34:09:648 +0700] [dd-remote-config] INFO com.datadog.debugger.agent.DebuggerAgent - Starting Exception Replay
[dd.trace 2026-02-18 07:34:09:652 +0700] [dd-remote-config] INFO com.datadog.debugger.agent.DebuggerAgent - Started Exception Replay

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/

 :: Spring Boot ::                (v3.3.5)

2026-02-18T07:34:11.317+07:00  INFO 3116 --- [           main] com.example.SpringDdReproApplication     : Starting SpringDdReproApplication using Java 17.0.4.1 with PID 3116 (C:\Users\alexa\Documents\java-src\SO_Java_SpringDataDogMethodParametersNotFound_79880361\target\classes started by alexa in C:\Users\alexa\Documents\java-src\SO_Java_SpringDataDogMethodParametersNotFound_79880361)
2026-02-18T07:34:11.324+07:00  INFO 3116 --- [           main] com.example.SpringDdReproApplication     : No active profile set, falling back to 1 default profile: "default"
2026-02-18T07:34:13.837+07:00  INFO 3116 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port 8080 (http)
2026-02-18T07:34:13.880+07:00  INFO 3116 --- [           main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
2026-02-18T07:34:13.880+07:00  INFO 3116 --- [           main] o.apache.catalina.core.StandardEngine    : Starting Servlet engine: [Apache Tomcat/10.1.31]
2026-02-18T07:34:13.973+07:00  INFO 3116 --- [           main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
2026-02-18T07:34:13.973+07:00  INFO 3116 --- [           main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 2570 ms
2026-02-18T07:34:14.888+07:00  INFO 3116 --- [           main] o.s.b.a.e.web.EndpointLinksResolver      : Exposing 2 endpoints beneath base path '/actuator'
2026-02-18T07:34:15.013+07:00  INFO 3116 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port 8080 (http) with context path '/'
2026-02-18T07:34:15.038+07:00  INFO 3116 --- [           main] com.example.SpringDdReproApplication     : Started SpringDdReproApplication in 4.82 seconds (process running for 9.09)
[dd.trace 2026-02-18 07:34:26:582 +0700] [dd-task-scheduler] SEND_TELEMETRY datadog.crashtracking.Initializer - Unsupported permissions 'rwxrwxrwx' for C:\Users\alexa\AppData\Local\Temp\ddprof_alexa\pid_3116. Crash tracking will not work properly.
[dd.trace 2026-02-18 07:34:26:705 +0700] [dd-task-scheduler] SEND_TELEMETRY datadog.crashtracking.Initializer - Unexpected exception while initializing OOME notifier. OOMEs will not be tracked. [null] (Change the logging level to debug to see the full stacktrace)
2026-02-18T07:42:35.115+07:00  INFO 3116 --- [nio-8080-exec-2] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring DispatcherServlet 'dispatcherServlet'
2026-02-18T07:42:35.115+07:00  INFO 3116 --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet        : Initializing Servlet 'dispatcherServlet'
2026-02-18T07:42:35.117+07:00  INFO 3116 --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet        : Completed initialization in 2 ms
2026-02-18T07:42:35.205+07:00 ERROR 3116 --- [nio-8080-exec-2] o.a.c.c.C.[.[.[/].[dispatcherServlet]    : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed: java.lang.IllegalArgumentException: Name for argument of type [java.lang.String] not specified, and parameter name information not available via reflection. Ensure that the compiler uses the '-parameters' flag.] with root cause

java.lang.IllegalArgumentException: Name for argument of type [java.lang.String] not specified, and parameter name information not available via reflection. Ensure that the compiler uses the '-parameters' flag.
	at org.springframework.web.method.annotation.AbstractNamedValueMethodArgumentResolver.updateNamedValueInfo(AbstractNamedValueMethodArgumentResolver.java:186) ~[spring-web-6.1.14.jar:6.1.14]
	at org.springframework.web.method.annotation.AbstractNamedValueMethodArgumentResolver.getNamedValueInfo(AbstractNamedValueMethodArgumentResolver.java:161) ~[spring-web-6.1.14.jar:6.1.14]
	at org.springframework.web.method.annotation.AbstractNamedValueMethodArgumentResolver.resolveArgument(AbstractNamedValueMethodArgumentResolver.java:107) ~[spring-web-6.1.14.jar:6.1.14]
	at org.springframework.web.method.support.HandlerMethodArgumentResolverComposite.resolveArgument(HandlerMethodArgumentResolverComposite.java:122) ~[spring-web-6.1.14.jar:6.1.14]
	at org.springframework.web.method.support.InvocableHandlerMethod.getMethodArgumentValues(InvocableHandlerMethod.java:224) ~[spring-web-6.1.14.jar:6.1.14]
	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:178) ~[spring-web-6.1.14.jar:6.1.14]
	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:118) ~[spring-webmvc-6.1.14.jar:6.1.14]
	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:926) ~[spring-webmvc-6.1.14.jar:6.1.14]
(...)

@desmond27
Copy link

desmond27 commented Feb 18, 2026

Nice. Now all I need to see is when this was enabled in prod on our end and I can close the RCA.

Thanks @kriegaex @jpbempel for the insightful comments.

Edit: One last question though @jpbempel . Does running a live debug session on Datadog trigger retransformation on all classes? Also, can exceptions encountered during runtime trigger it? I am asking because we faced this in multiple controllers that we didn't run added any log points to.

@jpbempel
Copy link
Member Author

Edit: One last question though @jpbempel . Does running a live debug session on Datadog trigger retransformation on all classes? Also, can exceptions encountered during runtime trigger it? I am asking because we faced this in multiple controllers that we didn't run added any log points to.

Live debugging is manual and only retransform the classes where you put a logpoint/probe.
Though, For Exception Replay it is automatic: when an exception is caught from and endpoint (related to a span) the stacktrace is analyzed and the top 3 user frames are instrumented (therefore retransformed)

Prevent classfiles with Method Parameters attribute
(javac -parameters) to be (re)transformed when on JDK < 19.
Spring 6+ or SpringBoot3+ rely exclusively on method parameters
to get param name and if the attribute is not present throw an
exception and returns 500 on endpoints.
see OpenJDK bug JDK-8240908.
we are scanning method with at least on parameter to detect if the
class was compiled with method parameters attribute and if the JDK
is < 19 we prevent instrumentation to happen.
Even at load time we prevent it because we need to call retransform
to remove instrumentation. Therefore the attribute can be strip at
that time.
canonical record constructor has method parameters attribute
@jpbempel jpbempel force-pushed the jpbempel/fix-method-parameters branch from f0f6ad1 to 5ba371e Compare February 20, 2026 18:08
@kriegaex
Copy link

kriegaex commented Feb 21, 2026

For documentation purposes, I want to share what I have learned in the last 30 minutes when experimenting with Spring Boot 1 and 2, because I was curious if it really worked without -parameters before: Yes, it did, because in addition to checking MethodParameters generated by -parameters, it also used debug info in the class's constant pool (if present) as a second path to find out variable names. In those older Spring (Boot) versions, if byte code was compiled without debug info, it would also throw similar exceptions as now without -parameters.

LocalVariableTableParameterNameDiscoverer has been removed since Spring 6.1, in 6.0 it was deprecated for removal. See Spring 6.1 release notes, where this fact and the migration path are clearly documented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: debugger Dynamic Instrumentation type: bug Bug report and fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants