Skip to content

Fix Oracle DBM trace correlation#10829

Merged
gh-worker-dd-mergequeue-cf854d[bot] merged 5 commits intomasterfrom
allen.zhou/oracle-java-tracer
Mar 19, 2026
Merged

Fix Oracle DBM trace correlation#10829
gh-worker-dd-mergequeue-cf854d[bot] merged 5 commits intomasterfrom
allen.zhou/oracle-java-tracer

Conversation

@azhou-datadog
Copy link
Contributor

What Does This Do

Fix Oracle DBM trace correlation by injecting the database instance name into dddbs and dddb SQL comment tags instead of the generic type string and null.

Motivation

https://datadoghq.atlassian.net/browse/SDBM-2434

On the APM service page, Oracle-backed services show broken DBM trace correlation:

  • @trace.span.service = "oracle" — the generic JDBC type string, not the database name
  • @trace.span.peer_db_name — always empty

Checked the oracle integration and backend pipeline are correct. The Java tracer is injecting the wrong values.

Root cause

Two bugs in the SQL comment injection path:

Bug 1 — dddbs='oracle' instead of the instance name:
getDbService() called dbService(type, instance) which, when split-by-instance=false (the default), ignores the
instance name and returns the type-based cache entry ("oracle").

Bug 2 — dddb always absent:
Both injection sites passed dbInfo.getDb() for the dddb tag. For Oracle, the JDBC URL parser sets instance only —
getDb() is always null — so dddb was silently skipped by SQLCommenter.

Fix

  • JDBCDecorator.getDbService(): if dbInfo.getInstance() is non-null, return it directly instead of going through the
    type-based naming cache. Uses getInstance() (not the dbInstance() fallback to getDb()) so databases like SQL Server
    that carry identity in getDb() are unaffected.
  • JDBCDecorator.getDbInstance(): new public accessor wrapping the protected dbInstance() method (returns instance ??
    db).
  • StatementInstrumentation: dddbs now uses DECORATE.getDbService(dbInfo) + service mapping (was
    span.getServiceName()); dddb now uses DECORATE.getDbInstance(dbInfo) (was dbInfo.getDb()).
  • DBMCompatibleConnectionInstrumentation: dddb now uses DECORATE.getDbInstance(dbInfo) (was dbInfo.getDb()).

Result

Oracle connections now inject:
/ddps='my-service',dddbs='freepdb1',ddh='localhost',dddb='freepdb1'/
instead of:
/ddps='my-service',dddbs='oracle',ddh='localhost'/

Testing

  • Added OracleInjectionForkedTest — two unit-level forked tests (prepared statement + single statement) asserting the
    correct comment format against a mock Oracle connection.
  • Added RemoteDBMTraceInjectedForkedTest#Oracle DBM comment... — an end-to-end test that spins up a real Oracle
    container (Testcontainers), runs a query, then queries v$sql as system to verify the exact SQL text Oracle received
    contains dddbs='freepdb1' and dddb='freepdb1' and does not contain dddbs='oracle'.

Additional Notes

Contributor Checklist

Jira ticket: https://datadoghq.atlassian.net/browse/SDBM-2434

Note: Once your PR is ready to merge, add it to the merge queue by commenting /merge. /merge -c cancels the queue request. /merge -f --reason "reason" skips all merge queue checks; please use this judiciously, as some checks do not run at the PR-level. For more information, see this doc.

@azhou-datadog azhou-datadog requested a review from a team as a code owner March 12, 2026 19:30
@azhou-datadog azhou-datadog added the comp: database Database Monitoring label Mar 12, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 12, 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.

@pr-commenter
Copy link

pr-commenter bot commented Mar 12, 2026

Benchmarks

Startup

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master allen.zhou/oracle-java-tracer
git_commit_date 1773845838 1773846843
git_commit_sha a953f33 7e99562
release_version 1.61.0-SNAPSHOT~a953f33c70 1.61.0-SNAPSHOT~7e995627f9
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1773848496 1773848496
ci_job_id 1517784397 1517784397
ci_pipeline_id 103293463 103293463
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-3-4zitbpf6 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-3-4zitbpf6 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 64 metrics, 7 unstable metrics.

Startup time reports for petclinic
gantt
    title petclinic - global startup overhead: candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.057 s) : 0, 1057287
Total [baseline] (11.081 s) : 0, 11080577
Agent [candidate] (1.057 s) : 0, 1056590
Total [candidate] (11.06 s) : 0, 11059608
section appsec
Agent [baseline] (1.246 s) : 0, 1246338
Total [baseline] (11.209 s) : 0, 11208855
Agent [candidate] (1.25 s) : 0, 1249967
Total [candidate] (11.207 s) : 0, 11206668
section iast
Agent [baseline] (1.229 s) : 0, 1228703
Total [baseline] (11.418 s) : 0, 11417788
Agent [candidate] (1.229 s) : 0, 1229277
Total [candidate] (11.317 s) : 0, 11316860
section profiling
Agent [baseline] (1.19 s) : 0, 1190442
Total [baseline] (11.078 s) : 0, 11077716
Agent [candidate] (1.187 s) : 0, 1186628
Total [candidate] (10.935 s) : 0, 10935320
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.057 s -
Agent appsec 1.246 s 189.052 ms (17.9%)
Agent iast 1.229 s 171.416 ms (16.2%)
Agent profiling 1.19 s 133.155 ms (12.6%)
Total tracing 11.081 s -
Total appsec 11.209 s 128.277 ms (1.2%)
Total iast 11.418 s 337.211 ms (3.0%)
Total profiling 11.078 s -2.862 ms (-0.0%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.057 s -
Agent appsec 1.25 s 193.378 ms (18.3%)
Agent iast 1.229 s 172.687 ms (16.3%)
Agent profiling 1.187 s 130.038 ms (12.3%)
Total tracing 11.06 s -
Total appsec 11.207 s 147.06 ms (1.3%)
Total iast 11.317 s 257.252 ms (2.3%)
Total profiling 10.935 s -124.288 ms (-1.1%)
gantt
    title petclinic - break down per module: candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70

    dateFormat X
    axisFormat %s
section tracing
crashtracking [baseline] (1.189 ms) : 0, 1189
crashtracking [candidate] (1.184 ms) : 0, 1184
BytebuddyAgent [baseline] (627.693 ms) : 0, 627693
BytebuddyAgent [candidate] (628.417 ms) : 0, 628417
AgentMeter [baseline] (29.143 ms) : 0, 29143
AgentMeter [candidate] (29.161 ms) : 0, 29161
GlobalTracer [baseline] (256.928 ms) : 0, 256928
GlobalTracer [candidate] (257.202 ms) : 0, 257202
AppSec [baseline] (31.626 ms) : 0, 31626
AppSec [candidate] (31.692 ms) : 0, 31692
Debugger [baseline] (60.268 ms) : 0, 60268
Debugger [candidate] (60.053 ms) : 0, 60053
Remote Config [baseline] (586.912 µs) : 0, 587
Remote Config [candidate] (584.59 µs) : 0, 585
Telemetry [baseline] (7.966 ms) : 0, 7966
Telemetry [candidate] (8.001 ms) : 0, 8001
Flare Poller [baseline] (5.865 ms) : 0, 5865
Flare Poller [candidate] (4.311 ms) : 0, 4311
section appsec
crashtracking [baseline] (1.181 ms) : 0, 1181
crashtracking [candidate] (1.19 ms) : 0, 1190
BytebuddyAgent [baseline] (658.001 ms) : 0, 658001
BytebuddyAgent [candidate] (660.363 ms) : 0, 660363
AgentMeter [baseline] (12.005 ms) : 0, 12005
AgentMeter [candidate] (12.014 ms) : 0, 12014
GlobalTracer [baseline] (257.913 ms) : 0, 257913
GlobalTracer [candidate] (259.028 ms) : 0, 259028
AppSec [baseline] (177.862 ms) : 0, 177862
AppSec [candidate] (177.842 ms) : 0, 177842
Debugger [baseline] (66.355 ms) : 0, 66355
Debugger [candidate] (66.313 ms) : 0, 66313
Remote Config [baseline] (620.712 µs) : 0, 621
Remote Config [candidate] (614.775 µs) : 0, 615
Telemetry [baseline] (8.341 ms) : 0, 8341
Telemetry [candidate] (8.292 ms) : 0, 8292
Flare Poller [baseline] (3.606 ms) : 0, 3606
Flare Poller [candidate] (3.536 ms) : 0, 3536
IAST [baseline] (24.201 ms) : 0, 24201
IAST [candidate] (24.371 ms) : 0, 24371
section iast
crashtracking [baseline] (1.188 ms) : 0, 1188
crashtracking [candidate] (1.195 ms) : 0, 1195
BytebuddyAgent [baseline] (797.062 ms) : 0, 797062
BytebuddyAgent [candidate] (797.175 ms) : 0, 797175
AgentMeter [baseline] (11.32 ms) : 0, 11320
AgentMeter [candidate] (11.357 ms) : 0, 11357
GlobalTracer [baseline] (247.134 ms) : 0, 247134
GlobalTracer [candidate] (247.671 ms) : 0, 247671
AppSec [baseline] (26.604 ms) : 0, 26604
AppSec [candidate] (27.469 ms) : 0, 27469
Debugger [baseline] (70.734 ms) : 0, 70734
Debugger [candidate] (69.925 ms) : 0, 69925
Remote Config [baseline] (538.43 µs) : 0, 538
Remote Config [candidate] (535.202 µs) : 0, 535
Telemetry [baseline] (9.304 ms) : 0, 9304
Telemetry [candidate] (9.236 ms) : 0, 9236
Flare Poller [baseline] (3.381 ms) : 0, 3381
Flare Poller [candidate] (3.348 ms) : 0, 3348
IAST [baseline] (25.346 ms) : 0, 25346
IAST [candidate] (25.261 ms) : 0, 25261
section profiling
crashtracking [baseline] (1.18 ms) : 0, 1180
crashtracking [candidate] (1.174 ms) : 0, 1174
BytebuddyAgent [baseline] (688.301 ms) : 0, 688301
BytebuddyAgent [candidate] (687.06 ms) : 0, 687060
AgentMeter [baseline] (8.68 ms) : 0, 8680
AgentMeter [candidate] (8.645 ms) : 0, 8645
GlobalTracer [baseline] (216.644 ms) : 0, 216644
GlobalTracer [candidate] (215.493 ms) : 0, 215493
AppSec [baseline] (32.394 ms) : 0, 32394
AppSec [candidate] (32.135 ms) : 0, 32135
Debugger [baseline] (64.751 ms) : 0, 64751
Debugger [candidate] (64.087 ms) : 0, 64087
Remote Config [baseline] (572.683 µs) : 0, 573
Remote Config [candidate] (561.648 µs) : 0, 562
Telemetry [baseline] (8.538 ms) : 0, 8538
Telemetry [candidate] (8.395 ms) : 0, 8395
Flare Poller [baseline] (4.279 ms) : 0, 4279
Flare Poller [candidate] (4.224 ms) : 0, 4224
ProfilingAgent [baseline] (93.972 ms) : 0, 93972
ProfilingAgent [candidate] (93.679 ms) : 0, 93679
Profiling [baseline] (94.536 ms) : 0, 94536
Profiling [candidate] (94.233 ms) : 0, 94233
Loading
Startup time reports for insecure-bank
gantt
    title insecure-bank - global startup overhead: candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.057 s) : 0, 1057345
Total [baseline] (8.876 s) : 0, 8876145
Agent [candidate] (1.054 s) : 0, 1054488
Total [candidate] (8.85 s) : 0, 8849963
section iast
Agent [baseline] (1.229 s) : 0, 1228823
Total [baseline] (9.591 s) : 0, 9591036
Agent [candidate] (1.228 s) : 0, 1228259
Total [candidate] (9.576 s) : 0, 9576227
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.057 s -
Agent iast 1.229 s 171.478 ms (16.2%)
Total tracing 8.876 s -
Total iast 9.591 s 714.891 ms (8.1%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.054 s -
Agent iast 1.228 s 173.772 ms (16.5%)
Total tracing 8.85 s -
Total iast 9.576 s 726.264 ms (8.2%)
gantt
    title insecure-bank - break down per module: candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70

    dateFormat X
    axisFormat %s
section tracing
crashtracking [baseline] (1.207 ms) : 0, 1207
crashtracking [candidate] (1.201 ms) : 0, 1201
BytebuddyAgent [baseline] (629.414 ms) : 0, 629414
BytebuddyAgent [candidate] (627.404 ms) : 0, 627404
AgentMeter [baseline] (29.264 ms) : 0, 29264
AgentMeter [candidate] (29.168 ms) : 0, 29168
GlobalTracer [baseline] (257.164 ms) : 0, 257164
GlobalTracer [candidate] (256.85 ms) : 0, 256850
AppSec [baseline] (31.727 ms) : 0, 31727
AppSec [candidate] (31.704 ms) : 0, 31704
Debugger [baseline] (59.638 ms) : 0, 59638
Debugger [candidate] (59.33 ms) : 0, 59330
Remote Config [baseline] (576.855 µs) : 0, 577
Remote Config [candidate] (581.253 µs) : 0, 581
Telemetry [baseline] (7.987 ms) : 0, 7987
Telemetry [candidate] (7.971 ms) : 0, 7971
Flare Poller [baseline] (4.247 ms) : 0, 4247
Flare Poller [candidate] (4.241 ms) : 0, 4241
section iast
crashtracking [baseline] (1.197 ms) : 0, 1197
crashtracking [candidate] (1.196 ms) : 0, 1196
BytebuddyAgent [baseline] (797.838 ms) : 0, 797838
BytebuddyAgent [candidate] (796.923 ms) : 0, 796923
AgentMeter [baseline] (11.349 ms) : 0, 11349
AgentMeter [candidate] (11.351 ms) : 0, 11351
GlobalTracer [baseline] (247.577 ms) : 0, 247577
GlobalTracer [candidate] (247.656 ms) : 0, 247656
AppSec [baseline] (26.469 ms) : 0, 26469
AppSec [candidate] (26.555 ms) : 0, 26555
Debugger [baseline] (69.243 ms) : 0, 69243
Debugger [candidate] (69.935 ms) : 0, 69935
Remote Config [baseline] (525.68 µs) : 0, 526
Remote Config [candidate] (531.126 µs) : 0, 531
Telemetry [baseline] (9.664 ms) : 0, 9664
Telemetry [candidate] (9.236 ms) : 0, 9236
Flare Poller [baseline] (3.469 ms) : 0, 3469
Flare Poller [candidate] (3.326 ms) : 0, 3326
IAST [baseline] (25.338 ms) : 0, 25338
IAST [candidate] (25.359 ms) : 0, 25359
Loading

Load

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master allen.zhou/oracle-java-tracer
git_commit_date 1773845838 1773846843
git_commit_sha a953f33 7e99562
release_version 1.61.0-SNAPSHOT~a953f33c70 1.61.0-SNAPSHOT~7e995627f9
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1773849071 1773849071
ci_job_id 1517784399 1517784399
ci_pipeline_id 103293463 103293463
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-12hwvxvb 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-12hwvxvb 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 1 performance improvements and 1 performance regressions! Performance is the same for 18 metrics, 16 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 worse
[+172.349µs; +430.574µs] or [+3.320%; +8.295%]
unsure
[+66.256µs; +903.010µs] or [+0.533%; +7.266%]
unstable
[-104.968op/s; +39.343op/s] or [-13.258%; +4.969%]
5.492ms 12.913ms 758.906op/s 5.191ms 12.429ms 791.719op/s
scenario:load:petclinic:no_agent:high_load better
[-1.946ms; -0.722ms] or [-10.360%; -3.846%]
unstable
[-3.298ms; -0.179ms] or [-10.588%; -0.574%]
unstable
[-8.786op/s; +43.411op/s] or [-3.638%; +17.975%]
17.446ms 29.405ms 258.812op/s 18.780ms 31.143ms 241.500op/s
Request duration reports for petclinic
gantt
    title petclinic - request duration [CI 0.99] : candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70
    dateFormat X
    axisFormat %s
section baseline
no_agent (19.327 ms) : 19129, 19524
.   : milestone, 19327,
appsec (18.449 ms) : 18257, 18641
.   : milestone, 18449,
code_origins (17.656 ms) : 17481, 17831
.   : milestone, 17656,
iast (18.086 ms) : 17904, 18267
.   : milestone, 18086,
profiling (18.622 ms) : 18431, 18813
.   : milestone, 18622,
tracing (18.021 ms) : 17840, 18203
.   : milestone, 18021,
section candidate
no_agent (18.032 ms) : 17848, 18216
.   : milestone, 18032,
appsec (18.448 ms) : 18261, 18635
.   : milestone, 18448,
code_origins (17.973 ms) : 17792, 18154
.   : milestone, 17973,
iast (17.693 ms) : 17515, 17872
.   : milestone, 17693,
profiling (18.537 ms) : 18357, 18718
.   : milestone, 18537,
tracing (17.827 ms) : 17651, 18003
.   : milestone, 17827,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 19.327 ms [19.129 ms, 19.524 ms] -
appsec 18.449 ms [18.257 ms, 18.641 ms] -878.018 µs (-4.5%)
code_origins 17.656 ms [17.481 ms, 17.831 ms] -1.671 ms (-8.6%)
iast 18.086 ms [17.904 ms, 18.267 ms] -1.241 ms (-6.4%)
profiling 18.622 ms [18.431 ms, 18.813 ms] -704.734 µs (-3.6%)
tracing 18.021 ms [17.84 ms, 18.203 ms] -1.305 ms (-6.8%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 18.032 ms [17.848 ms, 18.216 ms] -
appsec 18.448 ms [18.261 ms, 18.635 ms] 415.988 µs (2.3%)
code_origins 17.973 ms [17.792 ms, 18.154 ms] -59.415 µs (-0.3%)
iast 17.693 ms [17.515 ms, 17.872 ms] -338.931 µs (-1.9%)
profiling 18.537 ms [18.357 ms, 18.718 ms] 504.83 µs (2.8%)
tracing 17.827 ms [17.651 ms, 18.003 ms] -204.87 µs (-1.1%)
Request duration reports for insecure-bank
gantt
    title insecure-bank - request duration [CI 0.99] : candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.247 ms) : 1234, 1259
.   : milestone, 1247,
iast (3.081 ms) : 3037, 3124
.   : milestone, 3081,
iast_FULL (5.84 ms) : 5781, 5899
.   : milestone, 5840,
iast_GLOBAL (3.569 ms) : 3515, 3623
.   : milestone, 3569,
profiling (2.028 ms) : 2011, 2045
.   : milestone, 2028,
tracing (1.766 ms) : 1752, 1780
.   : milestone, 1766,
section candidate
no_agent (1.19 ms) : 1179, 1202
.   : milestone, 1190,
iast (3.135 ms) : 3094, 3175
.   : milestone, 3135,
iast_FULL (6.098 ms) : 6035, 6160
.   : milestone, 6098,
iast_GLOBAL (3.545 ms) : 3484, 3606
.   : milestone, 3545,
profiling (2.221 ms) : 2199, 2243
.   : milestone, 2221,
tracing (1.806 ms) : 1791, 1821
.   : milestone, 1806,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.247 ms [1.234 ms, 1.259 ms] -
iast 3.081 ms [3.037 ms, 3.124 ms] 1.834 ms (147.1%)
iast_FULL 5.84 ms [5.781 ms, 5.899 ms] 4.594 ms (368.5%)
iast_GLOBAL 3.569 ms [3.515 ms, 3.623 ms] 2.322 ms (186.3%)
profiling 2.028 ms [2.011 ms, 2.045 ms] 781.411 µs (62.7%)
tracing 1.766 ms [1.752 ms, 1.78 ms] 519.714 µs (41.7%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.19 ms [1.179 ms, 1.202 ms] -
iast 3.135 ms [3.094 ms, 3.175 ms] 1.945 ms (163.4%)
iast_FULL 6.098 ms [6.035 ms, 6.16 ms] 4.907 ms (412.4%)
iast_GLOBAL 3.545 ms [3.484 ms, 3.606 ms] 2.355 ms (197.9%)
profiling 2.221 ms [2.199 ms, 2.243 ms] 1.031 ms (86.7%)
tracing 1.806 ms [1.791 ms, 1.821 ms] 615.869 µs (51.7%)

Dacapo

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master allen.zhou/oracle-java-tracer
git_commit_date 1773845838 1773846843
git_commit_sha a953f33 7e99562
release_version 1.61.0-SNAPSHOT~a953f33c70 1.61.0-SNAPSHOT~7e995627f9
See matching parameters
Baseline Candidate
application biojava biojava
ci_job_date 1773848819 1773848819
ci_job_id 1517784401 1517784401
ci_pipeline_id 103293463 103293463
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-4-tfwjnwfd 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-4-tfwjnwfd 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 1 performance improvements and 0 performance regressions! Performance is the same for 11 metrics, 0 unstable metrics.

scenario Δ mean execution_time candidate mean execution_time baseline mean execution_time
scenario:dacapo:tomcat:appsec better
[-1.385ms; -1.044ms] or [-37.100%; -27.961%]
2.519ms 3.734ms
Execution time for tomcat
gantt
    title tomcat - execution time [CI 0.99] : candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.472 ms) : 1461, 1484
.   : milestone, 1472,
appsec (3.734 ms) : 3516, 3951
.   : milestone, 3734,
iast (2.254 ms) : 2185, 2323
.   : milestone, 2254,
iast_GLOBAL (2.294 ms) : 2225, 2364
.   : milestone, 2294,
profiling (2.07 ms) : 2015, 2124
.   : milestone, 2070,
tracing (2.067 ms) : 2014, 2121
.   : milestone, 2067,
section candidate
no_agent (1.472 ms) : 1460, 1483
.   : milestone, 1472,
appsec (2.519 ms) : 2464, 2574
.   : milestone, 2519,
iast (2.254 ms) : 2185, 2322
.   : milestone, 2254,
iast_GLOBAL (2.297 ms) : 2227, 2366
.   : milestone, 2297,
profiling (2.121 ms) : 2064, 2178
.   : milestone, 2121,
tracing (2.054 ms) : 2000, 2107
.   : milestone, 2054,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.472 ms [1.461 ms, 1.484 ms] -
appsec 3.734 ms [3.516 ms, 3.951 ms] 2.262 ms (153.6%)
iast 2.254 ms [2.185 ms, 2.323 ms] 781.608 µs (53.1%)
iast_GLOBAL 2.294 ms [2.225 ms, 2.364 ms] 822.317 µs (55.9%)
profiling 2.07 ms [2.015 ms, 2.124 ms] 597.501 µs (40.6%)
tracing 2.067 ms [2.014 ms, 2.121 ms] 595.287 µs (40.4%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.472 ms [1.46 ms, 1.483 ms] -
appsec 2.519 ms [2.464 ms, 2.574 ms] 1.047 ms (71.1%)
iast 2.254 ms [2.185 ms, 2.322 ms] 781.644 µs (53.1%)
iast_GLOBAL 2.297 ms [2.227 ms, 2.366 ms] 824.78 µs (56.0%)
profiling 2.121 ms [2.064 ms, 2.178 ms] 649.001 µs (44.1%)
tracing 2.054 ms [2.0 ms, 2.107 ms] 581.817 µs (39.5%)
Execution time for biojava
gantt
    title biojava - execution time [CI 0.99] : candidate=1.61.0-SNAPSHOT~7e995627f9, baseline=1.61.0-SNAPSHOT~a953f33c70
    dateFormat X
    axisFormat %s
section baseline
no_agent (15.462 s) : 15462000, 15462000
.   : milestone, 15462000,
appsec (14.618 s) : 14618000, 14618000
.   : milestone, 14618000,
iast (18.437 s) : 18437000, 18437000
.   : milestone, 18437000,
iast_GLOBAL (17.947 s) : 17947000, 17947000
.   : milestone, 17947000,
profiling (14.923 s) : 14923000, 14923000
.   : milestone, 14923000,
tracing (15.053 s) : 15053000, 15053000
.   : milestone, 15053000,
section candidate
no_agent (14.736 s) : 14736000, 14736000
.   : milestone, 14736000,
appsec (14.847 s) : 14847000, 14847000
.   : milestone, 14847000,
iast (18.331 s) : 18331000, 18331000
.   : milestone, 18331000,
iast_GLOBAL (18.201 s) : 18201000, 18201000
.   : milestone, 18201000,
profiling (14.853 s) : 14853000, 14853000
.   : milestone, 14853000,
tracing (14.804 s) : 14804000, 14804000
.   : milestone, 14804000,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.462 s [15.462 s, 15.462 s] -
appsec 14.618 s [14.618 s, 14.618 s] -844.0 ms (-5.5%)
iast 18.437 s [18.437 s, 18.437 s] 2.975 s (19.2%)
iast_GLOBAL 17.947 s [17.947 s, 17.947 s] 2.485 s (16.1%)
profiling 14.923 s [14.923 s, 14.923 s] -539.0 ms (-3.5%)
tracing 15.053 s [15.053 s, 15.053 s] -409.0 ms (-2.6%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 14.736 s [14.736 s, 14.736 s] -
appsec 14.847 s [14.847 s, 14.847 s] 111.0 ms (0.8%)
iast 18.331 s [18.331 s, 18.331 s] 3.595 s (24.4%)
iast_GLOBAL 18.201 s [18.201 s, 18.201 s] 3.465 s (23.5%)
profiling 14.853 s [14.853 s, 14.853 s] 117.0 ms (0.8%)
tracing 14.804 s [14.804 s, 14.804 s] 68.0 ms (0.5%)

@azhou-datadog azhou-datadog added the type: bug Bug report and fix label Mar 12, 2026
@azhou-datadog
Copy link
Contributor Author

@codex review

@chatgpt-codex-connector
Copy link

To use Codex here, create a Codex account and connect to github.

@vandonr
Copy link
Contributor

vandonr commented Mar 16, 2026

@codex review

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.

Reviewed commit: 5f04c0f9bf

ℹ️ 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".

def adminConn = java.sql.DriverManager.getConnection(adminUrl, "system", oracle.getPassword())
def rs = adminConn.createStatement().executeQuery(
"SELECT sql_fulltext FROM v\$sql " +
"WHERE sql_fulltext LIKE '%1729%' AND sql_fulltext LIKE '%dddbs%' " +

Choose a reason for hiding this comment

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

P2 Badge Exclude the admin lookup SQL from the v$sql match

This lookup can return the verifier query itself instead of the instrumented markerQuery, because the lookup SQL text contains both literals ('1729' and 'dddbs') used in its own LIKE filters and Oracle records executed statements in v$sql; with ROWNUM = 1, assertions may pass even if the target query was not injected correctly. Add a predicate that uniquely identifies the target statement (or excludes the lookup statement) so the test actually validates the intended SQL text.

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.

updated with adding like predicate on the comment

@vandonr vandonr added comp: api Tracer public API and removed comp: api Tracer public API labels Mar 18, 2026
dbService,
dbInfo.getType(),
dbInfo.getHost(),
DECORATE.isOracle(dbInfo) ? DECORATE.getDbInstance(dbInfo) : dbInfo.getDb(),
Copy link
Contributor

Choose a reason for hiding this comment

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

since it seems that all the info to return the correct data is contained in dbInfo, couldn't we put this logic in dbInfo.getDb() rather than having to write it explicitely here ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I took a look at dbInfo.getDb(), I'd rather not hide this logic in a pure getter function, as it could cause confusion down the line if there is splitting logic internally. If you're not a fan of this ternary here, I think we can also add a decorator method to JDBCDecorator, so the Oracle split lives there. Something like getDbNameForComment() or getDbForInjection()?

Copy link
Contributor

Choose a reason for hiding this comment

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

I was more thinking that some other place in the code could want the DB instance from the dbInfo, and they'd have to repeat the same logic, while if it's in the getter, we know it's always going to work.
Would there be any reason to not want to get the instance upon calling getDb on an oracle dbInfo ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see, that's fair. I'll push up a commit shortly

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated getDb so it simply returns instance if db is null

@azhou-datadog azhou-datadog requested a review from a team as a code owner March 18, 2026 14:44
@azhou-datadog azhou-datadog requested a review from dougqh March 18, 2026 14:44
@azhou-datadog azhou-datadog force-pushed the allen.zhou/oracle-java-tracer branch from d695249 to 7e99562 Compare March 18, 2026 15:14
@azhou-datadog azhou-datadog added this pull request to the merge queue Mar 18, 2026
@dd-octo-sts
Copy link
Contributor

dd-octo-sts bot commented Mar 18, 2026

/merge

@gh-worker-devflow-routing-ef8351
Copy link

gh-worker-devflow-routing-ef8351 bot commented Mar 18, 2026

View all feedbacks in Devflow UI.

2026-03-18 16:57:21 UTC ℹ️ Start processing command /merge


2026-03-18 16:57:26 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in master is approximately 3h (p90).


2026-03-18 18:59:03 UTCMergeQueue: The build pipeline has timeout

The merge request has been interrupted because the build 103327668 took longer than expected. The current limit for the base branch 'master' is 120 minutes.

@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Mar 18, 2026
@azhou-datadog
Copy link
Contributor Author

/merge

@gh-worker-devflow-routing-ef8351
Copy link

gh-worker-devflow-routing-ef8351 bot commented Mar 19, 2026

View all feedbacks in Devflow UI.

2026-03-19 02:05:12 UTC ℹ️ Start processing command /merge


2026-03-19 02:05:16 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in master is approximately 3h (p90).


2026-03-19 03:02:12 UTC ℹ️ MergeQueue: This merge request was merged

@gh-worker-dd-mergequeue-cf854d gh-worker-dd-mergequeue-cf854d bot merged commit c51637a into master Mar 19, 2026
566 checks passed
@gh-worker-dd-mergequeue-cf854d gh-worker-dd-mergequeue-cf854d bot deleted the allen.zhou/oracle-java-tracer branch March 19, 2026 03:02
@github-actions github-actions bot added this to the 1.61.0 milestone Mar 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: database Database Monitoring type: bug Bug report and fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants