Skip to content

Conversation

@vandonr
Copy link
Contributor

@vandonr vandonr commented Oct 16, 2025

What Does This Do

the JDBC instrumentation does extra calls to the DB to fetch the metadata and client info. In case this might cause issues, we want to be able to disable this behavior.
We'd still get some info to populate the DB tags from parsing the connection URL that's available without any extra call, but might be less representative of the truth than what we get from the metadata (for instance if the URL provided targets a cluster, the metdatada would give the exact instance we connected to)

Motivation

customer investigation

Additional Notes

Contributor Checklist

Jira ticket: APMS-16143

@datadog-official

This comment has been minimized.

@pr-commenter
Copy link

pr-commenter bot commented Oct 16, 2025

Benchmarks

Startup

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master vandonr/jdbc-ff
git_commit_date 1764633089 1764673207
git_commit_sha 4d1a38c fde1765
release_version 1.57.0-SNAPSHOT~4d1a38c992 1.55.0-SNAPSHOT~fde17658d3
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1764675067 1764675067
ci_job_id 1265383903 1265383903
ci_pipeline_id 84557503 84557503
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-i6m9nca4 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-i6m9nca4 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 54 metrics, 11 unstable metrics.

Startup time reports for petclinic
gantt
    title petclinic - global startup overhead: candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.061 s) : 0, 1060616
Total [baseline] (10.925 s) : 0, 10924826
Agent [candidate] (1.055 s) : 0, 1055049
Total [candidate] (10.883 s) : 0, 10882984
section appsec
Agent [baseline] (1.226 s) : 0, 1225958
Total [baseline] (10.889 s) : 0, 10889327
Agent [candidate] (1.232 s) : 0, 1231922
Total [candidate] (10.887 s) : 0, 10886863
section iast
Agent [baseline] (1.193 s) : 0, 1193384
Total [baseline] (11.203 s) : 0, 11203154
Agent [candidate] (1.202 s) : 0, 1202233
Total [candidate] (11.185 s) : 0, 11184872
section profiling
Agent [baseline] (1.201 s) : 0, 1201442
Total [baseline] (10.908 s) : 0, 10907909
Agent [candidate] (1.206 s) : 0, 1205629
Total [candidate] (10.943 s) : 0, 10942868
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.061 s -
Agent appsec 1.226 s 165.342 ms (15.6%)
Agent iast 1.193 s 132.769 ms (12.5%)
Agent profiling 1.201 s 140.826 ms (13.3%)
Total tracing 10.925 s -
Total appsec 10.889 s -35.5 ms (-0.3%)
Total iast 11.203 s 278.328 ms (2.5%)
Total profiling 10.908 s -16.917 ms (-0.2%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.055 s -
Agent appsec 1.232 s 176.873 ms (16.8%)
Agent iast 1.202 s 147.185 ms (14.0%)
Agent profiling 1.206 s 150.58 ms (14.3%)
Total tracing 10.883 s -
Total appsec 10.887 s 3.88 ms (0.0%)
Total iast 11.185 s 301.888 ms (2.8%)
Total profiling 10.943 s 59.884 ms (0.6%)
gantt
    title petclinic - break down per module: candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992

    dateFormat X
    axisFormat %s
section tracing
crashtracking [baseline] (1.501 ms) : 0, 1501
crashtracking [candidate] (1.481 ms) : 0, 1481
BytebuddyAgent [baseline] (712.432 ms) : 0, 712432
BytebuddyAgent [candidate] (708.548 ms) : 0, 708548
GlobalTracer [baseline] (251.475 ms) : 0, 251475
GlobalTracer [candidate] (250.562 ms) : 0, 250562
AppSec [baseline] (32.292 ms) : 0, 32292
AppSec [candidate] (32.099 ms) : 0, 32099
Debugger [baseline] (6.499 ms) : 0, 6499
Debugger [candidate] (6.42 ms) : 0, 6420
Remote Config [baseline] (688.025 µs) : 0, 688
Remote Config [candidate] (668.666 µs) : 0, 669
Telemetry [baseline] (15.014 ms) : 0, 15014
Telemetry [candidate] (14.743 ms) : 0, 14743
Flare Poller [baseline] (5.662 ms) : 0, 5662
Flare Poller [candidate] (5.67 ms) : 0, 5670
section appsec
crashtracking [baseline] (1.489 ms) : 0, 1489
crashtracking [candidate] (1.48 ms) : 0, 1480
BytebuddyAgent [baseline] (730.077 ms) : 0, 730077
BytebuddyAgent [candidate] (733.132 ms) : 0, 733132
GlobalTracer [baseline] (241.178 ms) : 0, 241178
GlobalTracer [candidate] (242.853 ms) : 0, 242853
AppSec [baseline] (174.505 ms) : 0, 174505
AppSec [candidate] (175.383 ms) : 0, 175383
Debugger [baseline] (6.245 ms) : 0, 6245
Debugger [candidate] (6.346 ms) : 0, 6346
Remote Config [baseline] (703.831 µs) : 0, 704
Remote Config [candidate] (688.167 µs) : 0, 688
Telemetry [baseline] (8.07 ms) : 0, 8070
Telemetry [candidate] (8.347 ms) : 0, 8347
Flare Poller [baseline] (3.961 ms) : 0, 3961
Flare Poller [candidate] (4.012 ms) : 0, 4012
IAST [baseline] (24.789 ms) : 0, 24789
IAST [candidate] (24.602 ms) : 0, 24602
section iast
crashtracking [baseline] (1.494 ms) : 0, 1494
crashtracking [candidate] (1.486 ms) : 0, 1486
BytebuddyAgent [baseline] (831.598 ms) : 0, 831598
BytebuddyAgent [candidate] (839.162 ms) : 0, 839162
GlobalTracer [baseline] (238.61 ms) : 0, 238610
GlobalTracer [candidate] (239.052 ms) : 0, 239052
AppSec [baseline] (29.341 ms) : 0, 29341
AppSec [candidate] (31.573 ms) : 0, 31573
Debugger [baseline] (5.968 ms) : 0, 5968
Debugger [candidate] (6.117 ms) : 0, 6117
Remote Config [baseline] (674.716 µs) : 0, 675
Remote Config [candidate] (613.975 µs) : 0, 614
Telemetry [baseline] (7.972 ms) : 0, 7972
Telemetry [candidate] (8.034 ms) : 0, 8034
Flare Poller [baseline] (10.728 ms) : 0, 10728
Flare Poller [candidate] (10.819 ms) : 0, 10819
IAST [baseline] (32.148 ms) : 0, 32148
IAST [candidate] (30.335 ms) : 0, 30335
section profiling
crashtracking [baseline] (1.442 ms) : 0, 1442
crashtracking [candidate] (1.473 ms) : 0, 1473
BytebuddyAgent [baseline] (735.605 ms) : 0, 735605
BytebuddyAgent [candidate] (739.54 ms) : 0, 739540
GlobalTracer [baseline] (223.059 ms) : 0, 223059
GlobalTracer [candidate] (222.749 ms) : 0, 222749
AppSec [baseline] (32.143 ms) : 0, 32143
AppSec [candidate] (32.166 ms) : 0, 32166
Debugger [baseline] (7.532 ms) : 0, 7532
Debugger [candidate] (6.922 ms) : 0, 6922
Remote Config [baseline] (685.812 µs) : 0, 686
Remote Config [candidate] (2.149 ms) : 0, 2149
Telemetry [baseline] (15.477 ms) : 0, 15477
Telemetry [candidate] (15.034 ms) : 0, 15034
Flare Poller [baseline] (4.162 ms) : 0, 4162
Flare Poller [candidate] (4.206 ms) : 0, 4206
ProfilingAgent [baseline] (111.987 ms) : 0, 111987
ProfilingAgent [candidate] (111.574 ms) : 0, 111574
Profiling [baseline] (112.639 ms) : 0, 112639
Profiling [candidate] (112.222 ms) : 0, 112222
Loading
Startup time reports for insecure-bank
gantt
    title insecure-bank - global startup overhead: candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.058 s) : 0, 1058093
Total [baseline] (8.692 s) : 0, 8691758
Agent [candidate] (1.054 s) : 0, 1053525
Total [candidate] (8.725 s) : 0, 8724602
section iast
Agent [baseline] (1.201 s) : 0, 1200903
Total [baseline] (9.352 s) : 0, 9352496
Agent [candidate] (1.192 s) : 0, 1192091
Total [candidate] (9.336 s) : 0, 9335606
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.058 s -
Agent iast 1.201 s 142.81 ms (13.5%)
Total tracing 8.692 s -
Total iast 9.352 s 660.738 ms (7.6%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.054 s -
Agent iast 1.192 s 138.566 ms (13.2%)
Total tracing 8.725 s -
Total iast 9.336 s 611.004 ms (7.0%)
gantt
    title insecure-bank - break down per module: candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992

    dateFormat X
    axisFormat %s
section tracing
crashtracking [baseline] (1.493 ms) : 0, 1493
crashtracking [candidate] (1.494 ms) : 0, 1494
BytebuddyAgent [baseline] (711.144 ms) : 0, 711144
BytebuddyAgent [candidate] (707.918 ms) : 0, 707918
GlobalTracer [baseline] (250.405 ms) : 0, 250405
GlobalTracer [candidate] (249.656 ms) : 0, 249656
AppSec [baseline] (32.241 ms) : 0, 32241
AppSec [candidate] (31.993 ms) : 0, 31993
Debugger [baseline] (6.433 ms) : 0, 6433
Debugger [candidate] (6.36 ms) : 0, 6360
Remote Config [baseline] (682.795 µs) : 0, 683
Remote Config [candidate] (685.154 µs) : 0, 685
Telemetry [baseline] (16.538 ms) : 0, 16538
Telemetry [candidate] (16.401 ms) : 0, 16401
Flare Poller [baseline] (4.138 ms) : 0, 4138
Flare Poller [candidate] (4.116 ms) : 0, 4116
section iast
crashtracking [baseline] (1.49 ms) : 0, 1490
crashtracking [candidate] (1.487 ms) : 0, 1487
BytebuddyAgent [baseline] (837.985 ms) : 0, 837985
BytebuddyAgent [candidate] (830.915 ms) : 0, 830915
GlobalTracer [baseline] (239.395 ms) : 0, 239395
GlobalTracer [candidate] (237.875 ms) : 0, 237875
AppSec [baseline] (30.524 ms) : 0, 30524
AppSec [candidate] (31.376 ms) : 0, 31376
Debugger [baseline] (6.057 ms) : 0, 6057
Debugger [candidate] (6.048 ms) : 0, 6048
Remote Config [baseline] (606.344 µs) : 0, 606
Remote Config [candidate] (603.101 µs) : 0, 603
Telemetry [baseline] (7.999 ms) : 0, 7999
Telemetry [candidate] (7.941 ms) : 0, 7941
Flare Poller [baseline] (10.77 ms) : 0, 10770
Flare Poller [candidate] (10.921 ms) : 0, 10921
IAST [baseline] (30.975 ms) : 0, 30975
IAST [candidate] (30.043 ms) : 0, 30043
Loading

Load

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master vandonr/jdbc-ff
git_commit_date 1764633089 1764673207
git_commit_sha 4d1a38c fde1765
release_version 1.57.0-SNAPSHOT~4d1a38c992 1.55.0-SNAPSHOT~fde17658d3
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1764675658 1764675658
ci_job_id 1265383905 1265383905
ci_pipeline_id 84557503 84557503
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-wk17gca8 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-wk17gca8 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 2 performance improvements and 0 performance regressions! Performance is the same for 16 metrics, 18 unstable metrics.

scenario Δ mean agg_http_req_duration_p50 Δ mean agg_http_req_duration_p95 Δ mean throughput candidate mean agg_http_req_duration_p50 candidate mean agg_http_req_duration_p95 candidate mean throughput baseline mean agg_http_req_duration_p50 baseline mean agg_http_req_duration_p95 baseline mean throughput
scenario:load:insecure-bank:iast_FULL:high_load unsure
[-266.170µs; -45.414µs] or [-5.087%; -0.868%]
better
[-882.405µs; -253.952µs] or [-7.055%; -2.031%]
unstable
[-55.975op/s; +111.850op/s] or [-7.154%; +14.295%]
5.077ms 11.939ms 810.375op/s 5.233ms 12.507ms 782.438op/s
scenario:load:petclinic:appsec:high_load better
[-1.690ms; -0.967ms] or [-8.694%; -4.975%]
unsure
[-1.750ms; -0.388ms] or [-5.620%; -1.245%]
unstable
[-8.537op/s; +40.912op/s] or [-3.613%; +17.315%]
18.110ms 30.074ms 252.469op/s 19.439ms 31.143ms 236.281op/s
Request duration reports for insecure-bank
gantt
    title insecure-bank - request duration [CI 0.99] : candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.206 ms) : 1194, 1217
.   : milestone, 1206,
iast (3.209 ms) : 3169, 3250
.   : milestone, 3209,
iast_FULL (5.91 ms) : 5850, 5969
.   : milestone, 5910,
iast_GLOBAL (3.697 ms) : 3635, 3759
.   : milestone, 3697,
profiling (2.129 ms) : 2110, 2149
.   : milestone, 2129,
tracing (1.836 ms) : 1820, 1852
.   : milestone, 1836,
section candidate
no_agent (1.214 ms) : 1202, 1226
.   : milestone, 1214,
iast (3.33 ms) : 3280, 3380
.   : milestone, 3330,
iast_FULL (5.702 ms) : 5646, 5758
.   : milestone, 5702,
iast_GLOBAL (3.538 ms) : 3486, 3590
.   : milestone, 3538,
profiling (2.068 ms) : 2048, 2087
.   : milestone, 2068,
tracing (1.81 ms) : 1795, 1825
.   : milestone, 1810,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.206 ms [1.194 ms, 1.217 ms] -
iast 3.209 ms [3.169 ms, 3.25 ms] 2.004 ms (166.2%)
iast_FULL 5.91 ms [5.85 ms, 5.969 ms] 4.704 ms (390.2%)
iast_GLOBAL 3.697 ms [3.635 ms, 3.759 ms] 2.491 ms (206.7%)
profiling 2.129 ms [2.11 ms, 2.149 ms] 923.686 µs (76.6%)
tracing 1.836 ms [1.82 ms, 1.852 ms] 630.026 µs (52.3%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.214 ms [1.202 ms, 1.226 ms] -
iast 3.33 ms [3.28 ms, 3.38 ms] 2.116 ms (174.3%)
iast_FULL 5.702 ms [5.646 ms, 5.758 ms] 4.488 ms (369.6%)
iast_GLOBAL 3.538 ms [3.486 ms, 3.59 ms] 2.324 ms (191.4%)
profiling 2.068 ms [2.048 ms, 2.087 ms] 853.621 µs (70.3%)
tracing 1.81 ms [1.795 ms, 1.825 ms] 595.937 µs (49.1%)
Request duration reports for petclinic
gantt
    title petclinic - request duration [CI 0.99] : candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992
    dateFormat X
    axisFormat %s
section baseline
no_agent (18.164 ms) : 17978, 18350
.   : milestone, 18164,
appsec (19.758 ms) : 19557, 19959
.   : milestone, 19758,
code_origins (17.709 ms) : 17533, 17884
.   : milestone, 17709,
iast (17.682 ms) : 17504, 17861
.   : milestone, 17682,
profiling (18.588 ms) : 18402, 18774
.   : milestone, 18588,
tracing (17.513 ms) : 17336, 17690
.   : milestone, 17513,
section candidate
no_agent (19.014 ms) : 18823, 19206
.   : milestone, 19014,
appsec (18.486 ms) : 18296, 18675
.   : milestone, 18486,
code_origins (17.69 ms) : 17513, 17866
.   : milestone, 17690,
iast (17.737 ms) : 17560, 17914
.   : milestone, 17737,
profiling (18.45 ms) : 18268, 18631
.   : milestone, 18450,
tracing (17.856 ms) : 17675, 18036
.   : milestone, 17856,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 18.164 ms [17.978 ms, 18.35 ms] -
appsec 19.758 ms [19.557 ms, 19.959 ms] 1.594 ms (8.8%)
code_origins 17.709 ms [17.533 ms, 17.884 ms] -455.345 µs (-2.5%)
iast 17.682 ms [17.504 ms, 17.861 ms] -481.679 µs (-2.7%)
profiling 18.588 ms [18.402 ms, 18.774 ms] 423.666 µs (2.3%)
tracing 17.513 ms [17.336 ms, 17.69 ms] -651.234 µs (-3.6%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 19.014 ms [18.823 ms, 19.206 ms] -
appsec 18.486 ms [18.296 ms, 18.675 ms] -528.675 µs (-2.8%)
code_origins 17.69 ms [17.513 ms, 17.866 ms] -1.325 ms (-7.0%)
iast 17.737 ms [17.56 ms, 17.914 ms] -1.277 ms (-6.7%)
profiling 18.45 ms [18.268 ms, 18.631 ms] -564.364 µs (-3.0%)
tracing 17.856 ms [17.675 ms, 18.036 ms] -1.159 ms (-6.1%)

Dacapo

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master vandonr/jdbc-ff
git_commit_date 1764633089 1764673207
git_commit_sha 4d1a38c fde1765
release_version 1.57.0-SNAPSHOT~4d1a38c992 1.55.0-SNAPSHOT~fde17658d3
See matching parameters
Baseline Candidate
application biojava biojava
ci_job_date 1764675312 1764675312
ci_job_id 1265383906 1265383906
ci_pipeline_id 84557503 84557503
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-d580pk8o 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-d580pk8o 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 10 metrics, 2 unstable metrics.

Execution time for biojava
gantt
    title biojava - execution time [CI 0.99] : candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992
    dateFormat X
    axisFormat %s
section baseline
no_agent (14.721 s) : 14721000, 14721000
.   : milestone, 14721000,
appsec (14.703 s) : 14703000, 14703000
.   : milestone, 14703000,
iast (18.396 s) : 18396000, 18396000
.   : milestone, 18396000,
iast_GLOBAL (17.933 s) : 17933000, 17933000
.   : milestone, 17933000,
profiling (15.378 s) : 15378000, 15378000
.   : milestone, 15378000,
tracing (14.664 s) : 14664000, 14664000
.   : milestone, 14664000,
section candidate
no_agent (15.087 s) : 15087000, 15087000
.   : milestone, 15087000,
appsec (14.714 s) : 14714000, 14714000
.   : milestone, 14714000,
iast (18.677 s) : 18677000, 18677000
.   : milestone, 18677000,
iast_GLOBAL (18.027 s) : 18027000, 18027000
.   : milestone, 18027000,
profiling (14.448 s) : 14448000, 14448000
.   : milestone, 14448000,
tracing (14.692 s) : 14692000, 14692000
.   : milestone, 14692000,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 14.721 s [14.721 s, 14.721 s] -
appsec 14.703 s [14.703 s, 14.703 s] -18.0 ms (-0.1%)
iast 18.396 s [18.396 s, 18.396 s] 3.675 s (25.0%)
iast_GLOBAL 17.933 s [17.933 s, 17.933 s] 3.212 s (21.8%)
profiling 15.378 s [15.378 s, 15.378 s] 657.0 ms (4.5%)
tracing 14.664 s [14.664 s, 14.664 s] -57.0 ms (-0.4%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.087 s [15.087 s, 15.087 s] -
appsec 14.714 s [14.714 s, 14.714 s] -373.0 ms (-2.5%)
iast 18.677 s [18.677 s, 18.677 s] 3.59 s (23.8%)
iast_GLOBAL 18.027 s [18.027 s, 18.027 s] 2.94 s (19.5%)
profiling 14.448 s [14.448 s, 14.448 s] -639.0 ms (-4.2%)
tracing 14.692 s [14.692 s, 14.692 s] -395.0 ms (-2.6%)
Execution time for tomcat
gantt
    title tomcat - execution time [CI 0.99] : candidate=1.55.0-SNAPSHOT~fde17658d3, baseline=1.57.0-SNAPSHOT~4d1a38c992
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.478 ms) : 1467, 1490
.   : milestone, 1478,
appsec (3.642 ms) : 3428, 3855
.   : milestone, 3642,
iast (2.226 ms) : 2161, 2291
.   : milestone, 2226,
iast_GLOBAL (2.273 ms) : 2208, 2338
.   : milestone, 2273,
profiling (2.115 ms) : 2061, 2170
.   : milestone, 2115,
tracing (2.076 ms) : 2025, 2127
.   : milestone, 2076,
section candidate
no_agent (1.479 ms) : 1468, 1491
.   : milestone, 1479,
appsec (3.691 ms) : 3474, 3909
.   : milestone, 3691,
iast (2.227 ms) : 2162, 2291
.   : milestone, 2227,
iast_GLOBAL (2.277 ms) : 2212, 2342
.   : milestone, 2277,
profiling (2.485 ms) : 2323, 2647
.   : milestone, 2485,
tracing (2.056 ms) : 2005, 2107
.   : milestone, 2056,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.478 ms [1.467 ms, 1.49 ms] -
appsec 3.642 ms [3.428 ms, 3.855 ms] 2.163 ms (146.3%)
iast 2.226 ms [2.161 ms, 2.291 ms] 747.501 µs (50.6%)
iast_GLOBAL 2.273 ms [2.208 ms, 2.338 ms] 794.391 µs (53.7%)
profiling 2.115 ms [2.061 ms, 2.17 ms] 637.113 µs (43.1%)
tracing 2.076 ms [2.025 ms, 2.127 ms] 597.565 µs (40.4%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.479 ms [1.468 ms, 1.491 ms] -
appsec 3.691 ms [3.474 ms, 3.909 ms] 2.212 ms (149.5%)
iast 2.227 ms [2.162 ms, 2.291 ms] 747.255 µs (50.5%)
iast_GLOBAL 2.277 ms [2.212 ms, 2.342 ms] 797.614 µs (53.9%)
profiling 2.485 ms [2.323 ms, 2.647 ms] 1.005 ms (68.0%)
tracing 2.056 ms [2.005 ms, 2.107 ms] 576.548 µs (39.0%)

try {
clientInfo = connection.getClientInfo();
} catch (final Throwable ex) {
// getClientInfo is likely not allowed, we can still extract info from the url alone
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe make sense to put some debug/trace log? Just thinking out loud.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

you mean for investigation in the current case, or in general ?

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 it could help for investigation in the current case! I have no scale for how often this method is called though -- would adding debug statements here be "okay" in a production environment where we don't want to spam logs?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added a log, we'll need to make sure this is not merged to main if we want to keep the feature flags for further investigations

Copy link
Contributor

Choose a reason for hiding this comment

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

Cool thanks! I'll add a do not merge tag for now to remind us

Copy link
Contributor Author

Choose a reason for hiding this comment

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

removed the tag as we actually want to merge, and also I think a debug log is no issue here (I was initially spooked by the "let's not log" above)

Copy link
Contributor

@AlexeyKuznetsov-DD AlexeyKuznetsov-DD left a comment

Choose a reason for hiding this comment

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

LGTM

@sarahchen6 sarahchen6 added the tag: do not merge Do not merge changes label Oct 20, 2025
@vandonr vandonr removed the tag: do not merge Do not merge changes label Dec 2, 2025
@vandonr vandonr marked this pull request as ready for review December 2, 2025 09:53
@vandonr vandonr requested review from a team as code owners December 2, 2025 09:53
@vandonr vandonr requested a review from mhlidd December 2, 2025 09:53
@vandonr
Copy link
Contributor Author

vandonr commented Dec 2, 2025

Marking ready for review, as testing with the customer has shown that this helps mitigate the high resource usage they were seeing with their setup, so this feels like a good option to have around.
The best would be to detect their kind of setup and flip the switch automatically (like we do for oracle in the driver instrumentation), but I don't think we have enough data/reproducibility at the moment to do that confidently.

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 49 to 53
def clientInfo = new Properties()
clientInfo.setProperty("warehouse", "my-test-warehouse") // we'll check that property to know if clientInfo were used
def connection = Mock(Connection) {
getMetaData() >> (shouldFetchMetadata() ? metadata : { assert false })
}

Choose a reason for hiding this comment

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

P1 Badge Stub client info in parseDBInfo regular-case test

The regular-case test builds a clientInfo with a warehouse value but the Connection mock only stubs getMetaData() and never returns that clientInfo. JDBCDecorator.parseDBInfoFromConnection will call connection.getClientInfo(), which currently returns null, so the subsequent assertions for result.warehouse == "my-test-warehouse" fail whenever metadata fetching is enabled. Please stub getClientInfo() to return the constructed clientInfo so the test exercises the intended code path.

Useful? React with 👍 / 👎.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

this is both true and false, the setup was incorrect, but also TIL the implicit asserts inside a block are not treated as asserts, so the test was still passing (asserting nothing) 🤦

@vandonr
Copy link
Contributor Author

vandonr commented Dec 2, 2025

@codex review

@chatgpt-codex-connector
Copy link

Codex Review: Didn't find any major issues. Can't wait for the next one!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@vandonr vandonr requested a review from a team as a code owner December 2, 2025 11:00
@vandonr vandonr requested review from PerfectSlayer and removed request for a team December 2, 2025 11:00
"DD_TRACE_CUCUMBER_5_ANALYTICS_ENABLED": ["DD_CUCUMBER_5_ANALYTICS_ENABLED"],
"DD_TRACE_CUCUMBER_ANALYTICS_ENABLED": ["DD_CUCUMBER_ANALYTICS_ENABLED"],
"DD_TRACE_DATANUCLEUS_ANALYTICS_ENABLED": ["DD_DATANUCLEUS_ANALYTICS_ENABLED"],
"DD_TRACE_DB_METADATA_FETCHING_ON_CONNECT": [
Copy link
Contributor

Choose a reason for hiding this comment

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

The two newly added configs don't have aliases so they can directly go into the supportedConfigurations key instead

Comment on lines +1675 to +1676
dbMetadataFetchingOnQuery = configProvider.getBoolean(DB_METADATA_FETCHING_ON_QUERY, true);
dbMetadataFetchingOnConnect = configProvider.getBoolean(DB_METADATA_FETCHING_ON_CONNECT, true);
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: Should the default values be defined in a static final in ConfigDefaults.java for consistency with other configs?

Config.get().isDbmTracePreparedStatements();
public static final boolean DBM_ALWAYS_APPEND_SQL_COMMENT =
Config.get().isDbmAlwaysAppendSqlComment();
public static final boolean FETCH_DB_METADATA_ON_CONNECT =
Copy link
Contributor

Choose a reason for hiding this comment

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

❓ (For my understanding) What is the reason to have one flag be public and the other be private? Isn't best practice for fields to be private and accessed through public getters? 🤔

Copy link
Contributor

@PerfectSlayer PerfectSlayer left a comment

Choose a reason for hiding this comment

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

Additional Notes
missing tests for now

According the PR content, it seems this was properly addressed?
Do we still miss some more tests?

Comment on lines +81 to +82
|| !Boolean.parseBoolean(
props.getProperty("oracle.jdbc.useShardingDriverConnection")))) {
Copy link
Contributor

Choose a reason for hiding this comment

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

🎯 suggestion: ‏IIRC, this comes from user configuration? If so, parseBoolean() can throw an exception if the value can't be parsed properly, breaking the instrumentation.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

hmm, this is not my code, it was here before, and also looking at the implementation, I see it as ((s != null) && s.equalsIgnoreCase("true")) in Java 8, i.e. it shouldn't throw and just default to false

@PerfectSlayer PerfectSlayer changed the title add a feature flag to disable extra calls to the DB in JDBC instrumentation Add a feature flag to disable extra calls to the DB in JDBC instrumentation Dec 2, 2025
@vandonr
Copy link
Contributor Author

vandonr commented Dec 3, 2025

it seems this was properly addressed? Do we still miss some more tests?

yes right I forgot to edit the description, I'll fix that

@vandonr vandonr merged commit ba2c056 into master Dec 4, 2025
543 checks passed
@vandonr vandonr deleted the vandonr/jdbc-ff branch December 4, 2025 13:37
@github-actions github-actions bot added this to the 1.57.0 milestone Dec 4, 2025
sarahchen6 pushed a commit that referenced this pull request Dec 10, 2025
sarahchen6 added a commit that referenced this pull request Dec 10, 2025
…tation (#9774) (#10161)

(cherry picked from commit ba2c056)

Co-authored-by: Raphaël Vandon <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants