Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Append comment on MySQL JDB callables #7742

Merged
merged 8 commits into from
Oct 11, 2024

Conversation

sethsamuel
Copy link
Contributor

@sethsamuel sethsamuel commented Oct 7, 2024

What Does This Do

Alters DBM comment injection to append the comment for MySQL statements wrapped in JDBC {} callable format. Added additional tests to validate this behavior.

Motivation

MySQL fails when the comment is prepended but succeeds when the comment is appended.

Additional Notes

Contributor Checklist

Jira ticket: [PROJ-IDENT]

@pr-commenter
Copy link

pr-commenter bot commented Oct 7, 2024

Benchmarks

Startup

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master seth.samuel/DBMON-4656-mysql-jdbc
git_commit_date 1728654019 1728658556
git_commit_sha eadf0cc 2f50239
release_version 1.41.0-SNAPSHOT~eadf0cc0d6 1.41.0-SNAPSHOT~2f502391e4
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1728660951 1728660951
ci_job_id 669964188 669964188
ci_pipeline_id 46397182 46397182
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
module Agent Agent
parent None None
variant iast iast

Summary

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

Startup time reports for petclinic
gantt
    title petclinic - global startup overhead: candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.069 s) : 0, 1069018
Total [baseline] (10.369 s) : 0, 10368870
Agent [candidate] (1.066 s) : 0, 1066330
Total [candidate] (10.366 s) : 0, 10366214
section appsec
Agent [baseline] (1.207 s) : 0, 1206917
Total [baseline] (10.589 s) : 0, 10589339
Agent [candidate] (1.204 s) : 0, 1203740
Total [candidate] (10.568 s) : 0, 10568364
section iast
Agent [baseline] (1.195 s) : 0, 1194509
Total [baseline] (10.84 s) : 0, 10840439
Agent [candidate] (1.195 s) : 0, 1194895
Total [candidate] (10.807 s) : 0, 10807128
section profiling
Agent [baseline] (1.264 s) : 0, 1263600
Total [baseline] (10.639 s) : 0, 10639182
Agent [candidate] (1.264 s) : 0, 1263557
Total [candidate] (10.553 s) : 0, 10553235
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.069 s -
Agent appsec 1.207 s 137.899 ms (12.9%)
Agent iast 1.195 s 125.491 ms (11.7%)
Agent profiling 1.264 s 194.583 ms (18.2%)
Total tracing 10.369 s -
Total appsec 10.589 s 220.469 ms (2.1%)
Total iast 10.84 s 471.569 ms (4.5%)
Total profiling 10.639 s 270.312 ms (2.6%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.066 s -
Agent appsec 1.204 s 137.41 ms (12.9%)
Agent iast 1.195 s 128.565 ms (12.1%)
Agent profiling 1.264 s 197.227 ms (18.5%)
Total tracing 10.366 s -
Total appsec 10.568 s 202.149 ms (2.0%)
Total iast 10.807 s 440.913 ms (4.3%)
Total profiling 10.553 s 187.02 ms (1.8%)
gantt
    title petclinic - break down per module: candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6

    dateFormat X
    axisFormat %s
section tracing
BytebuddyAgent [baseline] (682.096 ms) : 0, 682096
BytebuddyAgent [candidate] (680.061 ms) : 0, 680061
GlobalTracer [baseline] (311.089 ms) : 0, 311089
GlobalTracer [candidate] (310.904 ms) : 0, 310904
AppSec [baseline] (53.888 ms) : 0, 53888
AppSec [candidate] (53.413 ms) : 0, 53413
Remote Config [baseline] (658.32 µs) : 0, 658
Remote Config [candidate] (661.785 µs) : 0, 662
Telemetry [baseline] (7.651 ms) : 0, 7651
Telemetry [candidate] (7.625 ms) : 0, 7625
section appsec
BytebuddyAgent [baseline] (701.914 ms) : 0, 701914
BytebuddyAgent [candidate] (699.292 ms) : 0, 699292
GlobalTracer [baseline] (309.254 ms) : 0, 309254
GlobalTracer [candidate] (308.176 ms) : 0, 308176
AppSec [baseline] (162.367 ms) : 0, 162367
AppSec [candidate] (162.047 ms) : 0, 162047
IAST [baseline] (20.906 ms) : 0, 20906
IAST [candidate] (20.707 ms) : 0, 20707
Remote Config [baseline] (642.415 µs) : 0, 642
Remote Config [candidate] (632.789 µs) : 0, 633
Telemetry [baseline] (8.544 ms) : 0, 8544
Telemetry [candidate] (9.561 ms) : 0, 9561
section iast
BytebuddyAgent [baseline] (796.544 ms) : 0, 796544
BytebuddyAgent [candidate] (795.647 ms) : 0, 795647
GlobalTracer [baseline] (299.406 ms) : 0, 299406
GlobalTracer [candidate] (299.662 ms) : 0, 299662
AppSec [baseline] (54.508 ms) : 0, 54508
AppSec [candidate] (52.25 ms) : 0, 52250
IAST [baseline] (22.749 ms) : 0, 22749
IAST [candidate] (26.041 ms) : 0, 26041
Remote Config [baseline] (599.178 µs) : 0, 599
Remote Config [candidate] (612.155 µs) : 0, 612
Telemetry [baseline] (7.061 ms) : 0, 7061
Telemetry [candidate] (6.995 ms) : 0, 6995
section profiling
BytebuddyAgent [baseline] (673.643 ms) : 0, 673643
BytebuddyAgent [candidate] (673.304 ms) : 0, 673304
GlobalTracer [baseline] (392.181 ms) : 0, 392181
GlobalTracer [candidate] (393.115 ms) : 0, 393115
AppSec [baseline] (54.514 ms) : 0, 54514
AppSec [candidate] (54.421 ms) : 0, 54421
Remote Config [baseline] (653.374 µs) : 0, 653
Remote Config [candidate] (651.467 µs) : 0, 651
Telemetry [baseline] (7.391 ms) : 0, 7391
Telemetry [candidate] (7.416 ms) : 0, 7416
ProfilingAgent [baseline] (96.639 ms) : 0, 96639
ProfilingAgent [candidate] (96.107 ms) : 0, 96107
Profiling [baseline] (96.662 ms) : 0, 96662
Profiling [candidate] (96.131 ms) : 0, 96131
Loading
Startup time reports for insecure-bank
gantt
    title insecure-bank - global startup overhead: candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.087 s) : 0, 1086996
Total [baseline] (8.616 s) : 0, 8616410
Agent [candidate] (1.066 s) : 0, 1065875
Total [candidate] (8.561 s) : 0, 8560707
section iast
Agent [baseline] (1.193 s) : 0, 1192911
Total [baseline] (9.106 s) : 0, 9106375
Agent [candidate] (1.204 s) : 0, 1203534
Total [candidate] (9.117 s) : 0, 9117124
section iast_HARDCODED_SECRET_DISABLED
Agent [baseline] (1.195 s) : 0, 1195034
Total [baseline] (9.066 s) : 0, 9065928
Agent [candidate] (1.196 s) : 0, 1195543
Total [candidate] (9.074 s) : 0, 9074091
section iast_TELEMETRY_OFF
Agent [baseline] (1.199 s) : 0, 1199206
Total [baseline] (9.057 s) : 0, 9056756
Agent [candidate] (1.2 s) : 0, 1199887
Total [candidate] (9.072 s) : 0, 9071992
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.087 s -
Agent iast 1.193 s 105.915 ms (9.7%)
Agent iast_HARDCODED_SECRET_DISABLED 1.195 s 108.037 ms (9.9%)
Agent iast_TELEMETRY_OFF 1.199 s 112.21 ms (10.3%)
Total tracing 8.616 s -
Total iast 9.106 s 489.966 ms (5.7%)
Total iast_HARDCODED_SECRET_DISABLED 9.066 s 449.518 ms (5.2%)
Total iast_TELEMETRY_OFF 9.057 s 440.347 ms (5.1%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.066 s -
Agent iast 1.204 s 137.659 ms (12.9%)
Agent iast_HARDCODED_SECRET_DISABLED 1.196 s 129.668 ms (12.2%)
Agent iast_TELEMETRY_OFF 1.2 s 134.012 ms (12.6%)
Total tracing 8.561 s -
Total iast 9.117 s 556.418 ms (6.5%)
Total iast_HARDCODED_SECRET_DISABLED 9.074 s 513.384 ms (6.0%)
Total iast_TELEMETRY_OFF 9.072 s 511.286 ms (6.0%)
gantt
    title insecure-bank - break down per module: candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6

    dateFormat X
    axisFormat %s
section tracing
BytebuddyAgent [baseline] (692.983 ms) : 0, 692983
BytebuddyAgent [candidate] (680.316 ms) : 0, 680316
GlobalTracer [baseline] (316.829 ms) : 0, 316829
GlobalTracer [candidate] (310.103 ms) : 0, 310103
AppSec [baseline] (54.832 ms) : 0, 54832
AppSec [candidate] (53.573 ms) : 0, 53573
Remote Config [baseline] (682.344 µs) : 0, 682
Remote Config [candidate] (657.945 µs) : 0, 658
Telemetry [baseline] (7.782 ms) : 0, 7782
Telemetry [candidate] (7.599 ms) : 0, 7599
section iast
BytebuddyAgent [baseline] (794.803 ms) : 0, 794803
BytebuddyAgent [candidate] (801.855 ms) : 0, 801855
GlobalTracer [baseline] (298.822 ms) : 0, 298822
GlobalTracer [candidate] (301.504 ms) : 0, 301504
AppSec [baseline] (54.502 ms) : 0, 54502
AppSec [candidate] (56.449 ms) : 0, 56449
IAST [baseline] (23.475 ms) : 0, 23475
IAST [candidate] (22.213 ms) : 0, 22213
Remote Config [baseline] (593.11 µs) : 0, 593
Remote Config [candidate] (611.159 µs) : 0, 611
Telemetry [baseline] (7.043 ms) : 0, 7043
Telemetry [candidate] (7.119 ms) : 0, 7119
section iast_HARDCODED_SECRET_DISABLED
BytebuddyAgent [baseline] (795.59 ms) : 0, 795590
BytebuddyAgent [candidate] (795.773 ms) : 0, 795773
GlobalTracer [baseline] (299.596 ms) : 0, 299596
GlobalTracer [candidate] (300.036 ms) : 0, 300036
AppSec [baseline] (53.223 ms) : 0, 53223
AppSec [candidate] (54.827 ms) : 0, 54827
IAST [baseline] (25.227 ms) : 0, 25227
IAST [candidate] (23.53 ms) : 0, 23530
Remote Config [baseline] (602.845 µs) : 0, 603
Remote Config [candidate] (592.305 µs) : 0, 592
Telemetry [baseline] (7.092 ms) : 0, 7092
Telemetry [candidate] (7.045 ms) : 0, 7045
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (799.02 ms) : 0, 799020
BytebuddyAgent [candidate] (799.068 ms) : 0, 799068
GlobalTracer [baseline] (301.16 ms) : 0, 301160
GlobalTracer [candidate] (301.155 ms) : 0, 301155
AppSec [baseline] (56.868 ms) : 0, 56868
AppSec [candidate] (54.86 ms) : 0, 54860
IAST [baseline] (20.777 ms) : 0, 20777
IAST [candidate] (23.372 ms) : 0, 23372
Remote Config [baseline] (615.347 µs) : 0, 615
Remote Config [candidate] (606.924 µs) : 0, 607
Telemetry [baseline] (6.993 ms) : 0, 6993
Telemetry [candidate] (7.034 ms) : 0, 7034
Loading

Load

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
end_time 2024-10-11T15:06:24 2024-10-11T15:13:17
git_branch master seth.samuel/DBMON-4656-mysql-jdbc
git_commit_date 1728654019 1728658556
git_commit_sha eadf0cc 2f50239
release_version 1.41.0-SNAPSHOT~eadf0cc0d6 1.41.0-SNAPSHOT~2f502391e4
start_time 2024-10-11T15:06:11 2024-10-11T15:13:03
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1728659944 1728659944
ci_job_id 669964189 669964189
ci_pipeline_id 46397182 46397182
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
variant iast iast

Summary

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

Request duration reports for insecure-bank
gantt
    title insecure-bank - request duration [CI 0.99] : candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6
    dateFormat X
    axisFormat %s
section baseline
no_agent (376.306 µs) : 357, 396
.   : milestone, 376,
iast (497.269 µs) : 476, 519
.   : milestone, 497,
iast_FULL (555.952 µs) : 535, 577
.   : milestone, 556,
iast_GLOBAL (512.979 µs) : 492, 534
.   : milestone, 513,
iast_HARDCODED_SECRET_DISABLED (490.074 µs) : 469, 511
.   : milestone, 490,
iast_INACTIVE (456.818 µs) : 435, 479
.   : milestone, 457,
iast_TELEMETRY_OFF (485.533 µs) : 464, 507
.   : milestone, 486,
tracing (455.322 µs) : 434, 477
.   : milestone, 455,
section candidate
no_agent (374.953 µs) : 356, 394
.   : milestone, 375,
iast (489.692 µs) : 469, 511
.   : milestone, 490,
iast_FULL (557.707 µs) : 536, 579
.   : milestone, 558,
iast_GLOBAL (521.105 µs) : 499, 544
.   : milestone, 521,
iast_HARDCODED_SECRET_DISABLED (489.987 µs) : 469, 511
.   : milestone, 490,
iast_INACTIVE (455.032 µs) : 434, 476
.   : milestone, 455,
iast_TELEMETRY_OFF (476.239 µs) : 455, 498
.   : milestone, 476,
tracing (449.519 µs) : 429, 471
.   : milestone, 450,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 376.306 µs [356.708 µs, 395.904 µs] -
iast 497.269 µs [475.853 µs, 518.685 µs] 120.963 µs (32.1%)
iast_FULL 555.952 µs [534.857 µs, 577.048 µs] 179.646 µs (47.7%)
iast_GLOBAL 512.979 µs [491.667 µs, 534.292 µs] 136.674 µs (36.3%)
iast_HARDCODED_SECRET_DISABLED 490.074 µs [468.961 µs, 511.186 µs] 113.768 µs (30.2%)
iast_INACTIVE 456.818 µs [435.044 µs, 478.593 µs] 80.513 µs (21.4%)
iast_TELEMETRY_OFF 485.533 µs [464.279 µs, 506.786 µs] 109.227 µs (29.0%)
tracing 455.322 µs [434.142 µs, 476.501 µs] 79.016 µs (21.0%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 374.953 µs [355.536 µs, 394.37 µs] -
iast 489.692 µs [468.872 µs, 510.512 µs] 114.739 µs (30.6%)
iast_FULL 557.707 µs [536.341 µs, 579.073 µs] 182.754 µs (48.7%)
iast_GLOBAL 521.105 µs [498.657 µs, 543.554 µs] 146.152 µs (39.0%)
iast_HARDCODED_SECRET_DISABLED 489.987 µs [468.63 µs, 511.343 µs] 115.034 µs (30.7%)
iast_INACTIVE 455.032 µs [434.349 µs, 475.715 µs] 80.079 µs (21.4%)
iast_TELEMETRY_OFF 476.239 µs [454.733 µs, 497.744 µs] 101.286 µs (27.0%)
tracing 449.519 µs [428.528 µs, 470.511 µs] 74.566 µs (19.9%)
Request duration reports for petclinic
gantt
    title petclinic - request duration [CI 0.99] : candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.346 ms) : 1327, 1365
.   : milestone, 1346,
appsec (1.729 ms) : 1706, 1753
.   : milestone, 1729,
appsec_no_iast (1.728 ms) : 1705, 1752
.   : milestone, 1728,
iast (1.478 ms) : 1455, 1501
.   : milestone, 1478,
profiling (1.476 ms) : 1452, 1499
.   : milestone, 1476,
tracing (1.471 ms) : 1447, 1496
.   : milestone, 1471,
section candidate
no_agent (1.361 ms) : 1342, 1380
.   : milestone, 1361,
appsec (1.73 ms) : 1705, 1755
.   : milestone, 1730,
appsec_no_iast (1.72 ms) : 1696, 1744
.   : milestone, 1720,
iast (1.487 ms) : 1465, 1510
.   : milestone, 1487,
profiling (1.496 ms) : 1472, 1520
.   : milestone, 1496,
tracing (1.469 ms) : 1444, 1494
.   : milestone, 1469,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.346 ms [1.327 ms, 1.365 ms] -
appsec 1.729 ms [1.706 ms, 1.753 ms] 383.539 µs (28.5%)
appsec_no_iast 1.728 ms [1.705 ms, 1.752 ms] 382.322 µs (28.4%)
iast 1.478 ms [1.455 ms, 1.501 ms] 132.417 µs (9.8%)
profiling 1.476 ms [1.452 ms, 1.499 ms] 129.671 µs (9.6%)
tracing 1.471 ms [1.447 ms, 1.496 ms] 125.583 µs (9.3%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.361 ms [1.342 ms, 1.38 ms] -
appsec 1.73 ms [1.705 ms, 1.755 ms] 368.527 µs (27.1%)
appsec_no_iast 1.72 ms [1.696 ms, 1.744 ms] 358.407 µs (26.3%)
iast 1.487 ms [1.465 ms, 1.51 ms] 126.048 µs (9.3%)
profiling 1.496 ms [1.472 ms, 1.52 ms] 134.812 µs (9.9%)
tracing 1.469 ms [1.444 ms, 1.494 ms] 107.628 µs (7.9%)

Dacapo

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master seth.samuel/DBMON-4656-mysql-jdbc
git_commit_date 1728654019 1728658556
git_commit_sha eadf0cc 2f50239
release_version 1.41.0-SNAPSHOT~eadf0cc0d6 1.41.0-SNAPSHOT~2f502391e4
See matching parameters
Baseline Candidate
application biojava biojava
ci_job_date 1728660340 1728660340
ci_job_id 669964190 669964190
ci_pipeline_id 46397182 46397182
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
variant appsec appsec

Summary

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

Execution time for biojava
gantt
    title biojava - execution time [CI 0.99] : candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6
    dateFormat X
    axisFormat %s
section baseline
no_agent (15.014 s) : 15014000, 15014000
.   : milestone, 15014000,
appsec (15.076 s) : 15076000, 15076000
.   : milestone, 15076000,
iast (18.97 s) : 18970000, 18970000
.   : milestone, 18970000,
iast_GLOBAL (18.376 s) : 18376000, 18376000
.   : milestone, 18376000,
profiling (15.249 s) : 15249000, 15249000
.   : milestone, 15249000,
tracing (15.105 s) : 15105000, 15105000
.   : milestone, 15105000,
section candidate
no_agent (15.044 s) : 15044000, 15044000
.   : milestone, 15044000,
appsec (15.046 s) : 15046000, 15046000
.   : milestone, 15046000,
iast (18.815 s) : 18815000, 18815000
.   : milestone, 18815000,
iast_GLOBAL (18.031 s) : 18031000, 18031000
.   : milestone, 18031000,
profiling (15.717 s) : 15717000, 15717000
.   : milestone, 15717000,
tracing (15.297 s) : 15297000, 15297000
.   : milestone, 15297000,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.014 s [15.014 s, 15.014 s] -
appsec 15.076 s [15.076 s, 15.076 s] 62.0 ms (0.4%)
iast 18.97 s [18.97 s, 18.97 s] 3.956 s (26.3%)
iast_GLOBAL 18.376 s [18.376 s, 18.376 s] 3.362 s (22.4%)
profiling 15.249 s [15.249 s, 15.249 s] 235.0 ms (1.6%)
tracing 15.105 s [15.105 s, 15.105 s] 91.0 ms (0.6%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.044 s [15.044 s, 15.044 s] -
appsec 15.046 s [15.046 s, 15.046 s] 2.0 ms (0.0%)
iast 18.815 s [18.815 s, 18.815 s] 3.771 s (25.1%)
iast_GLOBAL 18.031 s [18.031 s, 18.031 s] 2.987 s (19.9%)
profiling 15.717 s [15.717 s, 15.717 s] 673.0 ms (4.5%)
tracing 15.297 s [15.297 s, 15.297 s] 253.0 ms (1.7%)
Execution time for tomcat
gantt
    title tomcat - execution time [CI 0.99] : candidate=1.41.0-SNAPSHOT~2f502391e4, baseline=1.41.0-SNAPSHOT~eadf0cc0d6
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.469 ms) : 1457, 1480
.   : milestone, 1469,
appsec (2.331 ms) : 2290, 2371
.   : milestone, 2331,
iast (2.078 ms) : 2026, 2129
.   : milestone, 2078,
iast_GLOBAL (2.131 ms) : 2079, 2183
.   : milestone, 2131,
profiling (1.967 ms) : 1925, 2009
.   : milestone, 1967,
tracing (1.932 ms) : 1893, 1971
.   : milestone, 1932,
section candidate
no_agent (1.475 ms) : 1464, 1487
.   : milestone, 1475,
appsec (2.337 ms) : 2296, 2378
.   : milestone, 2337,
iast (2.082 ms) : 2031, 2134
.   : milestone, 2082,
iast_GLOBAL (2.121 ms) : 2069, 2173
.   : milestone, 2121,
profiling (1.95 ms) : 1909, 1991
.   : milestone, 1950,
tracing (1.935 ms) : 1895, 1974
.   : milestone, 1935,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.469 ms [1.457 ms, 1.48 ms] -
appsec 2.331 ms [2.29 ms, 2.371 ms] 861.82 µs (58.7%)
iast 2.078 ms [2.026 ms, 2.129 ms] 608.872 µs (41.5%)
iast_GLOBAL 2.131 ms [2.079 ms, 2.183 ms] 662.133 µs (45.1%)
profiling 1.967 ms [1.925 ms, 2.009 ms] 497.787 µs (33.9%)
tracing 1.932 ms [1.893 ms, 1.971 ms] 462.944 µs (31.5%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.475 ms [1.464 ms, 1.487 ms] -
appsec 2.337 ms [2.296 ms, 2.378 ms] 862.035 µs (58.4%)
iast 2.082 ms [2.031 ms, 2.134 ms] 607.233 µs (41.2%)
iast_GLOBAL 2.121 ms [2.069 ms, 2.173 ms] 645.859 µs (43.8%)
profiling 1.95 ms [1.909 ms, 1.991 ms] 474.958 µs (32.2%)
tracing 1.935 ms [1.895 ms, 1.974 ms] 459.513 µs (31.2%)

@sethsamuel sethsamuel marked this pull request as ready for review October 8, 2024 13:09
@sethsamuel sethsamuel requested a review from a team as a code owner October 8, 2024 13:09
@PerfectSlayer PerfectSlayer added type: bug inst: jdbc JDBC instrumentation labels Oct 8, 2024
@@ -82,6 +82,11 @@ public static String inject(
return sql;
}

// Append the comment for mysql JDBC callable statements
if (firstWord.startsWith("{") && dbType.startsWith("mysql")) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

why mysql is not an exact match?

sethsamuel and others added 4 commits October 10, 2024 13:13
…/instrumentation/jdbc/SQLCommenter.java

Co-authored-by: datadog-datadog-prod-us1[bot] <88084959+datadog-datadog-prod-us1[bot]@users.noreply.github.com>
Recent Kotlin compiler generates multiple range for same local vars
and mess up our algorithm for adjustment.
Fix this by made a list of unique local vars
@sethsamuel sethsamuel requested a review from a team as a code owner October 11, 2024 13:40
@sethsamuel sethsamuel requested review from jpbempel and removed request for a team October 11, 2024 13:40
@pr-commenter
Copy link

pr-commenter bot commented Oct 11, 2024

Debugger benchmarks

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
ci_job_date 1728654628 1728655018
end_time 2024-10-11T13:51:43 2024-10-11T13:58:12
git_branch master seth.samuel/DBMON-4656-mysql-jdbc
git_commit_sha eadf0cc 188d110
start_time 2024-10-11T13:50:29 2024-10-11T13:56:59
See matching parameters
Baseline Candidate
ci_job_id 669812293 669812293
ci_pipeline_id 46388577 46388577
cpu_model Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz Intel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
git_commit_date 1728654014 1728654014

Summary

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

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:loop better
[-259.517µs; -181.811µs] or [-2.389%; -1.674%]
better
[-253.452µs; -169.887µs] or [-2.298%; -1.540%]
better
[-271.606µs; -157.608µs] or [-2.443%; -1.418%]
unsure
[-571.007µs; -16.307µs] or [-4.942%; -0.141%]
better
[+1.373op/s; +2.741op/s] or [+1.531%; +3.056%]
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
[-29.853µs; +11.371µs] or [-11.248%; +4.284%]
unstable
[-45.896µs; +19.526µs] or [-15.043%; +6.400%]
unstable
[-58.979µs; +30.089µs] or [-18.455%; +9.415%]
unstable
[-96157.488ns; +97138.649ns] or [-16.050%; +16.214%]
same
scenario:basic same same same unstable
[-40.139µs; +53.299µs] or [-7.615%; +10.112%]
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 (305.102 µs) : 267, 344
.   : milestone, 305,
basic (297.2 µs) : 287, 308
.   : milestone, 297,
loop (11.031 ms) : 11014, 11048
.   : milestone, 11031,
section candidate
noprobe (291.917 µs) : 270, 313
.   : milestone, 292,
basic (301.542 µs) : 293, 310
.   : milestone, 302,
loop (10.819 ms) : 10767, 10872
.   : milestone, 10819,
Loading
  • baseline results
Scenario Request median duration [CI 0.99]
noprobe 305.102 µs [266.533 µs, 343.671 µs]
basic 297.2 µs [286.648 µs, 307.753 µs]
loop 11.031 ms [11.014 ms, 11.048 ms]
  • candidate results
Scenario Request median duration [CI 0.99]
noprobe 291.917 µs [270.474 µs, 313.361 µs]
basic 301.542 µs [293.173 µs, 309.911 µs]
loop 10.819 ms [10.767 ms, 10.872 ms]

@sethsamuel sethsamuel merged commit b69d348 into master Oct 11, 2024
104 checks passed
@sethsamuel sethsamuel deleted the seth.samuel/DBMON-4656-mysql-jdbc branch October 11, 2024 16:32
@github-actions github-actions bot added this to the 1.41.0 milestone Oct 11, 2024
manuel-alvarez-alvarez pushed a commit that referenced this pull request Oct 16, 2024
Append comment on MySQL JDB callables

(cherry picked from commit b69d348)
manuel-alvarez-alvarez added a commit that referenced this pull request Oct 16, 2024
…bc (#7771)

Append comment on MySQL JDB callables

(cherry picked from commit b69d348)

Co-authored-by: Seth Samuel <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
inst: jdbc JDBC instrumentation type: bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants