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

Cassandra: allow extracting keyspace from statement result #8239

Merged
merged 3 commits into from
Jan 21, 2025

Conversation

amarziali
Copy link
Collaborator

@amarziali amarziali commented Jan 17, 2025

What Does This Do

Today the db.instance tag for cassandra is obtained by using the keyspace used to initialize the session.
Using a keyspace to create a session is not mandatory but if it's specified it will be the one used by default.

However, a different keyspace can be used in the cql statements and in reality is that one that should be used instead.

This PR allows sourcing the db.instance from the metadata of the query results. It works only with statements that produces results (i.e. not with query like DROP NAMESPACE... , etc.. )

The feature is opt-in since it would be a breaking change. In fact, settings a different db.instance would impact:

  • The peer.service (hence the trace stats)
  • The service name if split by instance is enabled

In order to activate this feature:

  • Set the system property -Ddd.trace.cassandra.keyspace.statement.extraction.enabled=true
  • Set the env var DD_TRACE_CASSANDRA_KEYSPACE_STATEMENT_EXTRACTION_ENABLED=true

Motivation

Additional Notes

Contributor Checklist

Jira ticket: APMS-14356

@amarziali amarziali requested review from a team as code owners January 17, 2025 11:22
@amarziali amarziali requested a review from mcculls January 17, 2025 11:22
Copy link
Contributor

github-actions bot commented Jan 17, 2025

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 Jan 17, 2025

Benchmarks

Startup

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master andrea.marziali/cassandra-peer
git_commit_date 1737460501 1737461227
git_commit_sha 693c605 94da60d
release_version 1.46.0-SNAPSHOT~693c605f76 1.46.0-SNAPSHOT~94da60d255
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1737463580 1737463580
ci_job_id 773851521 773851521
ci_pipeline_id 53541161 53541161
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 58 metrics, 5 unstable metrics.

Startup time reports for petclinic
gantt
    title petclinic - global startup overhead: candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.055 s) : 0, 1055286
Total [baseline] (10.461 s) : 0, 10460634
Agent [candidate] (1.055 s) : 0, 1054989
Total [candidate] (10.448 s) : 0, 10447739
section appsec
Agent [baseline] (1.193 s) : 0, 1193006
Total [baseline] (10.665 s) : 0, 10664731
Agent [candidate] (1.194 s) : 0, 1194161
Total [candidate] (10.728 s) : 0, 10728426
section iast
Agent [baseline] (1.185 s) : 0, 1184773
Total [baseline] (11.031 s) : 0, 11031005
Agent [candidate] (1.185 s) : 0, 1184723
Total [candidate] (11.027 s) : 0, 11027475
section profiling
Agent [baseline] (1.256 s) : 0, 1256078
Total [baseline] (10.769 s) : 0, 10768525
Agent [candidate] (1.256 s) : 0, 1255753
Total [candidate] (10.782 s) : 0, 10782183
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.055 s -
Agent appsec 1.193 s 137.72 ms (13.1%)
Agent iast 1.185 s 129.487 ms (12.3%)
Agent profiling 1.256 s 200.792 ms (19.0%)
Total tracing 10.461 s -
Total appsec 10.665 s 204.096 ms (2.0%)
Total iast 11.031 s 570.37 ms (5.5%)
Total profiling 10.769 s 307.891 ms (2.9%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.055 s -
Agent appsec 1.194 s 139.172 ms (13.2%)
Agent iast 1.185 s 129.734 ms (12.3%)
Agent profiling 1.256 s 200.764 ms (19.0%)
Total tracing 10.448 s -
Total appsec 10.728 s 280.688 ms (2.7%)
Total iast 11.027 s 579.736 ms (5.5%)
Total profiling 10.782 s 334.444 ms (3.2%)
gantt
    title petclinic - break down per module: candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76

    dateFormat X
    axisFormat %s
section tracing
BytebuddyAgent [baseline] (713.613 ms) : 0, 713613
BytebuddyAgent [candidate] (713.844 ms) : 0, 713844
GlobalTracer [baseline] (255.564 ms) : 0, 255564
GlobalTracer [candidate] (255.128 ms) : 0, 255128
AppSec [baseline] (55.54 ms) : 0, 55540
AppSec [candidate] (56.779 ms) : 0, 56779
Remote Config [baseline] (740.724 µs) : 0, 741
Remote Config [candidate] (720.419 µs) : 0, 720
Telemetry [baseline] (14.905 ms) : 0, 14905
Telemetry [candidate] (13.528 ms) : 0, 13528
section appsec
BytebuddyAgent [baseline] (734.382 ms) : 0, 734382
BytebuddyAgent [candidate] (734.987 ms) : 0, 734987
GlobalTracer [baseline] (253.826 ms) : 0, 253826
GlobalTracer [candidate] (254.493 ms) : 0, 254493
AppSec [baseline] (171.324 ms) : 0, 171324
AppSec [candidate] (170.646 ms) : 0, 170646
Remote Config [baseline] (660.645 µs) : 0, 661
Remote Config [candidate] (662.331 µs) : 0, 662
Telemetry [baseline] (8.155 ms) : 0, 8155
Telemetry [candidate] (8.577 ms) : 0, 8577
IAST [baseline] (19.368 ms) : 0, 19368
IAST [candidate] (19.51 ms) : 0, 19510
section iast
BytebuddyAgent [baseline] (833.287 ms) : 0, 833287
BytebuddyAgent [candidate] (833.873 ms) : 0, 833873
GlobalTracer [baseline] (247.036 ms) : 0, 247036
GlobalTracer [candidate] (246.425 ms) : 0, 246425
AppSec [baseline] (58.288 ms) : 0, 58288
AppSec [candidate] (58.135 ms) : 0, 58135
Remote Config [baseline] (665.96 µs) : 0, 666
Remote Config [candidate] (671.442 µs) : 0, 671
Telemetry [baseline] (8.811 ms) : 0, 8811
Telemetry [candidate] (8.823 ms) : 0, 8823
IAST [baseline] (21.693 ms) : 0, 21693
IAST [candidate] (21.727 ms) : 0, 21727
section profiling
ProfilingAgent [baseline] (95.227 ms) : 0, 95227
ProfilingAgent [candidate] (95.748 ms) : 0, 95748
BytebuddyAgent [baseline] (705.139 ms) : 0, 705139
BytebuddyAgent [candidate] (703.952 ms) : 0, 703952
GlobalTracer [baseline] (349.325 ms) : 0, 349325
GlobalTracer [candidate] (349.96 ms) : 0, 349960
AppSec [baseline] (54.878 ms) : 0, 54878
AppSec [candidate] (54.527 ms) : 0, 54527
Remote Config [baseline] (703.835 µs) : 0, 704
Remote Config [candidate] (710.101 µs) : 0, 710
Telemetry [baseline] (8.835 ms) : 0, 8835
Telemetry [candidate] (8.92 ms) : 0, 8920
Profiling [baseline] (95.251 ms) : 0, 95251
Profiling [candidate] (95.773 ms) : 0, 95773
Loading
Startup time reports for insecure-bank
gantt
    title insecure-bank - global startup overhead: candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76

    dateFormat X
    axisFormat %s
section tracing
Agent [baseline] (1.065 s) : 0, 1064549
Total [baseline] (8.674 s) : 0, 8673576
Agent [candidate] (1.058 s) : 0, 1057973
Total [candidate] (8.606 s) : 0, 8606378
section iast
Agent [baseline] (1.182 s) : 0, 1181666
Total [baseline] (9.197 s) : 0, 9196571
Agent [candidate] (1.184 s) : 0, 1183987
Total [candidate] (9.16 s) : 0, 9159741
section iast_HARDCODED_SECRET_DISABLED
Agent [baseline] (1.184 s) : 0, 1184351
Total [baseline] (9.164 s) : 0, 9163758
Agent [candidate] (1.199 s) : 0, 1199438
Total [candidate] (9.199 s) : 0, 9198702
section iast_TELEMETRY_OFF
Agent [baseline] (1.181 s) : 0, 1180588
Total [baseline] (9.176 s) : 0, 9176313
Agent [candidate] (1.18 s) : 0, 1179547
Total [candidate] (9.179 s) : 0, 9178963
Loading
  • baseline results
Module Variant Duration Δ tracing
Agent tracing 1.065 s -
Agent iast 1.182 s 117.117 ms (11.0%)
Agent iast_HARDCODED_SECRET_DISABLED 1.184 s 119.803 ms (11.3%)
Agent iast_TELEMETRY_OFF 1.181 s 116.039 ms (10.9%)
Total tracing 8.674 s -
Total iast 9.197 s 522.995 ms (6.0%)
Total iast_HARDCODED_SECRET_DISABLED 9.164 s 490.181 ms (5.7%)
Total iast_TELEMETRY_OFF 9.176 s 502.737 ms (5.8%)
  • candidate results
Module Variant Duration Δ tracing
Agent tracing 1.058 s -
Agent iast 1.184 s 126.014 ms (11.9%)
Agent iast_HARDCODED_SECRET_DISABLED 1.199 s 141.465 ms (13.4%)
Agent iast_TELEMETRY_OFF 1.18 s 121.574 ms (11.5%)
Total tracing 8.606 s -
Total iast 9.16 s 553.363 ms (6.4%)
Total iast_HARDCODED_SECRET_DISABLED 9.199 s 592.324 ms (6.9%)
Total iast_TELEMETRY_OFF 9.179 s 572.586 ms (6.7%)
gantt
    title insecure-bank - break down per module: candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76

    dateFormat X
    axisFormat %s
section tracing
BytebuddyAgent [baseline] (719.901 ms) : 0, 719901
BytebuddyAgent [candidate] (715.878 ms) : 0, 715878
GlobalTracer [baseline] (257.7 ms) : 0, 257700
GlobalTracer [candidate] (255.857 ms) : 0, 255857
AppSec [baseline] (56.619 ms) : 0, 56619
AppSec [candidate] (57.1 ms) : 0, 57100
Remote Config [baseline] (756.841 µs) : 0, 757
Remote Config [candidate] (741.795 µs) : 0, 742
Telemetry [baseline] (14.529 ms) : 0, 14529
Telemetry [candidate] (13.403 ms) : 0, 13403
section iast
BytebuddyAgent [baseline] (831.529 ms) : 0, 831529
BytebuddyAgent [candidate] (832.969 ms) : 0, 832969
GlobalTracer [baseline] (246.208 ms) : 0, 246208
GlobalTracer [candidate] (247.237 ms) : 0, 247237
AppSec [baseline] (58.016 ms) : 0, 58016
AppSec [candidate] (58.031 ms) : 0, 58031
IAST [baseline] (21.522 ms) : 0, 21522
IAST [candidate] (21.383 ms) : 0, 21383
Remote Config [baseline] (667.147 µs) : 0, 667
Remote Config [candidate] (671.699 µs) : 0, 672
Telemetry [baseline] (8.744 ms) : 0, 8744
Telemetry [candidate] (8.69 ms) : 0, 8690
section iast_HARDCODED_SECRET_DISABLED
BytebuddyAgent [baseline] (832.675 ms) : 0, 832675
BytebuddyAgent [candidate] (845.37 ms) : 0, 845370
GlobalTracer [baseline] (246.886 ms) : 0, 246886
GlobalTracer [candidate] (248.948 ms) : 0, 248948
AppSec [baseline] (58.439 ms) : 0, 58439
AppSec [candidate] (58.523 ms) : 0, 58523
IAST [baseline] (21.848 ms) : 0, 21848
IAST [candidate] (21.712 ms) : 0, 21712
Remote Config [baseline] (667.469 µs) : 0, 667
Remote Config [candidate] (676.875 µs) : 0, 677
Telemetry [baseline] (8.818 ms) : 0, 8818
Telemetry [candidate] (8.795 ms) : 0, 8795
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (829.419 ms) : 0, 829419
BytebuddyAgent [candidate] (830.051 ms) : 0, 830051
GlobalTracer [baseline] (247.249 ms) : 0, 247249
GlobalTracer [candidate] (246.36 ms) : 0, 246360
AppSec [baseline] (57.585 ms) : 0, 57585
AppSec [candidate] (58.043 ms) : 0, 58043
IAST [baseline] (21.988 ms) : 0, 21988
IAST [candidate] (20.807 ms) : 0, 20807
Remote Config [baseline] (658.448 µs) : 0, 658
Remote Config [candidate] (647.957 µs) : 0, 648
Telemetry [baseline] (8.724 ms) : 0, 8724
Telemetry [candidate] (8.556 ms) : 0, 8556
Loading

Load

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
end_time 2025-01-21T12:16:19 2025-01-21T12:23:24
git_branch master andrea.marziali/cassandra-peer
git_commit_date 1737460501 1737461227
git_commit_sha 693c605 94da60d
release_version 1.46.0-SNAPSHOT~693c605f76 1.46.0-SNAPSHOT~94da60d255
start_time 2025-01-21T12:16:06 2025-01-21T12:23:10
See matching parameters
Baseline Candidate
application insecure-bank insecure-bank
ci_job_date 1737462563 1737462563
ci_job_id 773851522 773851522
ci_pipeline_id 53541161 53541161
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 petclinic
gantt
    title petclinic - request duration [CI 0.99] : candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.354 ms) : 1334, 1373
.   : milestone, 1354,
appsec (1.749 ms) : 1725, 1773
.   : milestone, 1749,
appsec_no_iast (1.76 ms) : 1738, 1783
.   : milestone, 1760,
iast (1.522 ms) : 1498, 1546
.   : milestone, 1522,
profiling (1.544 ms) : 1519, 1568
.   : milestone, 1544,
tracing (1.492 ms) : 1469, 1516
.   : milestone, 1492,
section candidate
no_agent (1.367 ms) : 1348, 1386
.   : milestone, 1367,
appsec (1.756 ms) : 1732, 1780
.   : milestone, 1756,
appsec_no_iast (1.771 ms) : 1745, 1796
.   : milestone, 1771,
iast (1.513 ms) : 1488, 1537
.   : milestone, 1513,
profiling (1.523 ms) : 1498, 1548
.   : milestone, 1523,
tracing (1.49 ms) : 1466, 1515
.   : milestone, 1490,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.354 ms [1.334 ms, 1.373 ms] -
appsec 1.749 ms [1.725 ms, 1.773 ms] 395.273 µs (29.2%)
appsec_no_iast 1.76 ms [1.738 ms, 1.783 ms] 406.468 µs (30.0%)
iast 1.522 ms [1.498 ms, 1.546 ms] 168.388 µs (12.4%)
profiling 1.544 ms [1.519 ms, 1.568 ms] 189.958 µs (14.0%)
tracing 1.492 ms [1.469 ms, 1.516 ms] 138.599 µs (10.2%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 1.367 ms [1.348 ms, 1.386 ms] -
appsec 1.756 ms [1.732 ms, 1.78 ms] 388.65 µs (28.4%)
appsec_no_iast 1.771 ms [1.745 ms, 1.796 ms] 403.549 µs (29.5%)
iast 1.513 ms [1.488 ms, 1.537 ms] 145.7 µs (10.7%)
profiling 1.523 ms [1.498 ms, 1.548 ms] 155.817 µs (11.4%)
tracing 1.49 ms [1.466 ms, 1.515 ms] 123.299 µs (9.0%)
Request duration reports for insecure-bank
gantt
    title insecure-bank - request duration [CI 0.99] : candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76
    dateFormat X
    axisFormat %s
section baseline
no_agent (375.441 µs) : 355, 396
.   : milestone, 375,
iast (501.576 µs) : 480, 523
.   : milestone, 502,
iast_FULL (743.451 µs) : 721, 765
.   : milestone, 743,
iast_GLOBAL (555.976 µs) : 534, 578
.   : milestone, 556,
iast_HARDCODED_SECRET_DISABLED (506.993 µs) : 486, 528
.   : milestone, 507,
iast_INACTIVE (460.013 µs) : 438, 482
.   : milestone, 460,
iast_TELEMETRY_OFF (493.504 µs) : 472, 515
.   : milestone, 494,
tracing (450.3 µs) : 430, 471
.   : milestone, 450,
section candidate
no_agent (384.182 µs) : 363, 405
.   : milestone, 384,
iast (502.874 µs) : 481, 525
.   : milestone, 503,
iast_FULL (744.293 µs) : 722, 766
.   : milestone, 744,
iast_GLOBAL (553.685 µs) : 531, 576
.   : milestone, 554,
iast_HARDCODED_SECRET_DISABLED (507.398 µs) : 486, 529
.   : milestone, 507,
iast_INACTIVE (454.048 µs) : 433, 475
.   : milestone, 454,
iast_TELEMETRY_OFF (495.572 µs) : 474, 517
.   : milestone, 496,
tracing (456.306 µs) : 435, 478
.   : milestone, 456,
Loading
  • baseline results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 375.441 µs [355.375 µs, 395.506 µs] -
iast 501.576 µs [480.087 µs, 523.065 µs] 126.135 µs (33.6%)
iast_FULL 743.451 µs [721.413 µs, 765.489 µs] 368.01 µs (98.0%)
iast_GLOBAL 555.976 µs [533.706 µs, 578.246 µs] 180.535 µs (48.1%)
iast_HARDCODED_SECRET_DISABLED 506.993 µs [485.504 µs, 528.482 µs] 131.552 µs (35.0%)
iast_INACTIVE 460.013 µs [438.299 µs, 481.727 µs] 84.572 µs (22.5%)
iast_TELEMETRY_OFF 493.504 µs [471.992 µs, 515.016 µs] 118.063 µs (31.4%)
tracing 450.3 µs [429.662 µs, 470.939 µs] 74.86 µs (19.9%)
  • candidate results
Variant Request duration [CI 0.99] Δ no_agent
no_agent 384.182 µs [363.031 µs, 405.333 µs] -
iast 502.874 µs [481.214 µs, 524.535 µs] 118.693 µs (30.9%)
iast_FULL 744.293 µs [722.258 µs, 766.329 µs] 360.111 µs (93.7%)
iast_GLOBAL 553.685 µs [531.337 µs, 576.033 µs] 169.503 µs (44.1%)
iast_HARDCODED_SECRET_DISABLED 507.398 µs [485.955 µs, 528.842 µs] 123.216 µs (32.1%)
iast_INACTIVE 454.048 µs [433.182 µs, 474.913 µs] 69.866 µs (18.2%)
iast_TELEMETRY_OFF 495.572 µs [473.676 µs, 517.469 µs] 111.39 µs (29.0%)
tracing 456.306 µs [434.852 µs, 477.761 µs] 72.125 µs (18.8%)

Dacapo

Parameters

Baseline Candidate
baseline_or_candidate baseline candidate
git_branch master andrea.marziali/cassandra-peer
git_commit_date 1737460501 1737461227
git_commit_sha 693c605 94da60d
release_version 1.46.0-SNAPSHOT~693c605f76 1.46.0-SNAPSHOT~94da60d255
See matching parameters
Baseline Candidate
application biojava biojava
ci_job_date 1737463133 1737463133
ci_job_id 773851523 773851523
ci_pipeline_id 53541161 53541161
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 11 metrics, 1 unstable metrics.

Execution time for tomcat
gantt
    title tomcat - execution time [CI 0.99] : candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76
    dateFormat X
    axisFormat %s
section baseline
no_agent (1.479 ms) : 1467, 1490
.   : milestone, 1479,
appsec (2.371 ms) : 2328, 2415
.   : milestone, 2371,
iast (2.112 ms) : 2058, 2166
.   : milestone, 2112,
iast_GLOBAL (2.154 ms) : 2100, 2209
.   : milestone, 2154,
profiling (1.976 ms) : 1932, 2020
.   : milestone, 1976,
tracing (1.946 ms) : 1905, 1988
.   : milestone, 1946,
section candidate
no_agent (1.478 ms) : 1466, 1490
.   : milestone, 1478,
appsec (2.355 ms) : 2312, 2397
.   : milestone, 2355,
iast (2.109 ms) : 2055, 2163
.   : milestone, 2109,
iast_GLOBAL (2.159 ms) : 2104, 2214
.   : milestone, 2159,
profiling (2.456 ms) : 2212, 2701
.   : milestone, 2456,
tracing (1.956 ms) : 1914, 1998
.   : milestone, 1956,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.479 ms [1.467 ms, 1.49 ms] -
appsec 2.371 ms [2.328 ms, 2.415 ms] 892.621 µs (60.4%)
iast 2.112 ms [2.058 ms, 2.166 ms] 633.62 µs (42.8%)
iast_GLOBAL 2.154 ms [2.1 ms, 2.209 ms] 675.522 µs (45.7%)
profiling 1.976 ms [1.932 ms, 2.02 ms] 496.841 µs (33.6%)
tracing 1.946 ms [1.905 ms, 1.988 ms] 467.661 µs (31.6%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 1.478 ms [1.466 ms, 1.49 ms] -
appsec 2.355 ms [2.312 ms, 2.397 ms] 876.422 µs (59.3%)
iast 2.109 ms [2.055 ms, 2.163 ms] 631.104 µs (42.7%)
iast_GLOBAL 2.159 ms [2.104 ms, 2.214 ms] 681.223 µs (46.1%)
profiling 2.456 ms [2.212 ms, 2.701 ms] 978.135 µs (66.2%)
tracing 1.956 ms [1.914 ms, 1.998 ms] 477.742 µs (32.3%)
Execution time for biojava
gantt
    title biojava - execution time [CI 0.99] : candidate=1.46.0-SNAPSHOT~94da60d255, baseline=1.46.0-SNAPSHOT~693c605f76
    dateFormat X
    axisFormat %s
section baseline
no_agent (15.041 s) : 15041000, 15041000
.   : milestone, 15041000,
appsec (14.973 s) : 14973000, 14973000
.   : milestone, 14973000,
iast (18.521 s) : 18521000, 18521000
.   : milestone, 18521000,
iast_GLOBAL (18.064 s) : 18064000, 18064000
.   : milestone, 18064000,
profiling (15.733 s) : 15733000, 15733000
.   : milestone, 15733000,
tracing (15.052 s) : 15052000, 15052000
.   : milestone, 15052000,
section candidate
no_agent (15.024 s) : 15024000, 15024000
.   : milestone, 15024000,
appsec (14.971 s) : 14971000, 14971000
.   : milestone, 14971000,
iast (18.547 s) : 18547000, 18547000
.   : milestone, 18547000,
iast_GLOBAL (17.761 s) : 17761000, 17761000
.   : milestone, 17761000,
profiling (15.09 s) : 15090000, 15090000
.   : milestone, 15090000,
tracing (15.163 s) : 15163000, 15163000
.   : milestone, 15163000,
Loading
  • baseline results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.041 s [15.041 s, 15.041 s] -
appsec 14.973 s [14.973 s, 14.973 s] -68.0 ms (-0.5%)
iast 18.521 s [18.521 s, 18.521 s] 3.48 s (23.1%)
iast_GLOBAL 18.064 s [18.064 s, 18.064 s] 3.023 s (20.1%)
profiling 15.733 s [15.733 s, 15.733 s] 692.0 ms (4.6%)
tracing 15.052 s [15.052 s, 15.052 s] 11.0 ms (0.1%)
  • candidate results
Variant Execution Time [CI 0.99] Δ no_agent
no_agent 15.024 s [15.024 s, 15.024 s] -
appsec 14.971 s [14.971 s, 14.971 s] -53.0 ms (-0.4%)
iast 18.547 s [18.547 s, 18.547 s] 3.523 s (23.4%)
iast_GLOBAL 17.761 s [17.761 s, 17.761 s] 2.737 s (18.2%)
profiling 15.09 s [15.09 s, 15.09 s] 66.0 ms (0.4%)
tracing 15.163 s [15.163 s, 15.163 s] 139.0 ms (0.9%)

@amarziali amarziali force-pushed the andrea.marziali/cassandra-peer branch from e6257ec to 44ccc6c Compare January 17, 2025 13:14
@amarziali amarziali added comp: api Tracer public API and removed comp: api Tracer public API labels Jan 17, 2025
Copy link
Contributor

@mcculls mcculls left a comment

Choose a reason for hiding this comment

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

Nice refactoring and good use of a feature-flag.

Will there be a documentation update for this?

@amarziali amarziali force-pushed the andrea.marziali/cassandra-peer branch from 44ccc6c to 94da60d Compare January 21, 2025 12:07
@amarziali
Copy link
Collaborator Author

Nice refactoring and good use of a feature-flag.

Will there be a documentation update for this?

Thanks Stuart. Yes I've few updates in the doc (also for this PR) to do as soon as 1.46.0 will be out

@amarziali amarziali enabled auto-merge (squash) January 21, 2025 12:09
@amarziali amarziali added comp: api Tracer public API and removed comp: api Tracer public API labels Jan 21, 2025
@amarziali amarziali merged commit 2b72cb5 into master Jan 21, 2025
174 of 175 checks passed
@amarziali amarziali deleted the andrea.marziali/cassandra-peer branch January 21, 2025 14:04
@github-actions github-actions bot added this to the 1.46.0 milestone Jan 21, 2025
svc-squareup-copybara pushed a commit to cashapp/misk that referenced this pull request Jan 31, 2025
| Package | Type | Package file | Manager | Update | Change |
|---|---|---|---|---|---|
|
[com.google.cloud:google-cloud-datastore](https://github.com/googleapis/java-datastore)
| dependencies | misk/gradle/libs.versions.toml | gradle | minor |
`2.25.4` -> `2.26.0` |
| [com.datadoghq:dd-trace-api](https://github.com/datadog/dd-trace-java)
| dependencies | misk/gradle/libs.versions.toml | gradle | minor |
`1.45.2` -> `1.46.0` |
| [com.datadoghq:dd-trace-ot](https://github.com/datadog/dd-trace-java)
| dependencies | misk/gradle/libs.versions.toml | gradle | minor |
`1.45.2` -> `1.46.0` |
| [software.amazon.awssdk:sdk-core](https://aws.amazon.com/sdkforjava) |
dependencies | misk/gradle/libs.versions.toml | gradle | patch |
`2.30.9` -> `2.30.10` |
|
[software.amazon.awssdk:dynamodb-enhanced](https://aws.amazon.com/sdkforjava)
| dependencies | misk/gradle/libs.versions.toml | gradle | patch |
`2.30.9` -> `2.30.10` |
| [software.amazon.awssdk:dynamodb](https://aws.amazon.com/sdkforjava) |
dependencies | misk/gradle/libs.versions.toml | gradle | patch |
`2.30.9` -> `2.30.10` |
| [software.amazon.awssdk:aws-core](https://aws.amazon.com/sdkforjava) |
dependencies | misk/gradle/libs.versions.toml | gradle | patch |
`2.30.9` -> `2.30.10` |
| [software.amazon.awssdk:bom](https://aws.amazon.com/sdkforjava) |
dependencies | misk/gradle/libs.versions.toml | gradle | patch |
`2.30.9` -> `2.30.10` |
| [software.amazon.awssdk:auth](https://aws.amazon.com/sdkforjava) |
dependencies | misk/gradle/libs.versions.toml | gradle | patch |
`2.30.9` -> `2.30.10` |

---

### Release Notes

<details>
<summary>googleapis/java-datastore
(com.google.cloud:google-cloud-datastore)</summary>

###
[`v2.26.0`](https://github.com/googleapis/java-datastore/blob/HEAD/CHANGELOG.md#2260-2025-01-29)

##### Features

- Add firestoreInDatastoreMode for datastore emulator
([#&#8203;1698](googleapis/java-datastore#1698))
([50f106d](googleapis/java-datastore@50f106d))

##### Dependencies

- Update dependency com.google.cloud:sdk-platform-java-config to v3.42.0
([#&#8203;1725](googleapis/java-datastore#1725))
([1cbaf22](googleapis/java-datastore@1cbaf22))

</details>

<details>
<summary>datadog/dd-trace-java (com.datadoghq:dd-trace-api)</summary>

###
[`v1.46.0`](https://github.com/DataDog/dd-trace-java/releases/tag/v1.46.0):
1.46.0

##### Breaking Changes

> \[!WARNING]
> jnr-unixsocket is now an external dependency of dd-trace-ot and must
be included when deploying dd-trace-ot.

> \[!NOTE]
> The API `TracerScope.setAsync(boolean)`, used to manually control
asynchronous span propagation, does no more apply to the scope instance
but to the active span scope.

##### Components

##### Application Security Management (IAST)

- 🐛 Fix String.replace instrumentation for IAST
([#&#8203;8281](DataDog/dd-trace-java#8281) -
[@&#8203;Mariovido](https://github.com/Mariovido))
- ✨ Apply the standard nomenclature to the stacktrace configs
([#&#8203;8244](DataDog/dd-trace-java#8244) -
[@&#8203;jandro996](https://github.com/jandro996))
- 🐛 Exclude false positive weak randomness
([#&#8203;8232](DataDog/dd-trace-java#8232) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Propagation of translateEscapes of String class
([#&#8203;8186](DataDog/dd-trace-java#8186) -
[@&#8203;sezen-datadog](https://github.com/sezen-datadog))
- ✨ Add security control metrics
([#&#8203;8175](DataDog/dd-trace-java#8175) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Increase IAST propagation to StringBuffer setLength
([#&#8203;8128](DataDog/dd-trace-java#8128) -
[@&#8203;Mariovido](https://github.com/Mariovido))
- ✨ Add IAST taint tracking for DB values
([#&#8203;8072](DataDog/dd-trace-java#8072) -
[@&#8203;Mariovido](https://github.com/Mariovido))

##### Application Security Management (WAF)

- 🐛 Prevents a NPE when there is no subscriber for user events
([#&#8203;8258](DataDog/dd-trace-java#8258) -
[@&#8203;manuel-alvarez-alvarez](https://github.com/manuel-alvarez-alvarez))
- ✨ Apply the standard nomenclature to the stacktrace configs
([#&#8203;8244](DataDog/dd-trace-java#8244) -
[@&#8203;jandro996](https://github.com/jandro996))
- 🐛 Ensure cached subscriptions are cleared on reconfiguration via
RC ([#&#8203;8229](DataDog/dd-trace-java#8229)
-
[@&#8203;manuel-alvarez-alvarez](https://github.com/manuel-alvarez-alvarez))
- ✨ Add support for session tracking in Vertx
([#&#8203;8167](DataDog/dd-trace-java#8167) -
[@&#8203;manuel-alvarez-alvarez](https://github.com/manuel-alvarez-alvarez))
- ✨ Create span tag: \_dd.appsec.rasp.timeout
([#&#8203;8269](DataDog/dd-trace-java#8269) -
[@&#8203;Mariovido](https://github.com/Mariovido))

##### Build & Tooling

- 🐛 Ensure shaded helpers have unique names when injected into
class-loaders
([#&#8203;8192](DataDog/dd-trace-java#8192) -
[@&#8203;mcculls](https://github.com/mcculls))

##### Configuration at Runtime

- 🐛 Remove filtering of `DD_SERVICE` and `DD_ENV` from the tracer
([#&#8203;8176](DataDog/dd-trace-java#8176) -
[@&#8203;mhlidd](https://github.com/mhlidd))

##### Continuous Integration Visibility

- 🧹 Generalize TestRetryPolicy to TestExecutionPolicy
([#&#8203;8302](DataDog/dd-trace-java#8302) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🧹 Parallelize CI Visibility settings requests
([#&#8203;8299](DataDog/dd-trace-java#8299) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🧹 Generalize test retry logic
([#&#8203;8289](DataDog/dd-trace-java#8289) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🧹 Generalize tests skipping logic
([#&#8203;8288](DataDog/dd-trace-java#8288) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🧹 Remove skip and shouldBeSkipped methods from TestEventsHandler
in favor of isSkippable
([#&#8203;8286](DataDog/dd-trace-java#8286) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- ✨⚡ Optimize Git repository information computation
([#&#8203;8270](DataDog/dd-trace-java#8270) -
[@&#8203;dougqh](https://github.com/dougqh))
- ✨ Always request known tests from the backend
([#&#8203;8268](DataDog/dd-trace-java#8268) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- ✨ Fix NPE when trying to get retry analyzer in Test NG
([#&#8203;8253](DataDog/dd-trace-java#8253) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🐛 Set test framework and test framework version tags atomically
([#&#8203;8252](DataDog/dd-trace-java#8252) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- ✨ Add debug logging to Android Gradle module layout logic
([#&#8203;8251](DataDog/dd-trace-java#8251) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🐛 Fix source and destination folders computation for Android
Gradle projects
([#&#8203;8190](DataDog/dd-trace-java#8190) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- ✨ Add basic Scala Weaver sbt support
([#&#8203;8189](DataDog/dd-trace-java#8189) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Implement impacted tests detection
([#&#8203;8188](DataDog/dd-trace-java#8188) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))

##### Data Streams Monitoring

- ✨ Change hash computation for protobuf to better represent
impacting changes + save proto number in schema
([#&#8203;8201](DataDog/dd-trace-java#8201) -
[@&#8203;vandonr](https://github.com/vandonr))

##### Database Monitoring

- Add peer service tag in dbm sql commenter
([#&#8203;7913](DataDog/dd-trace-java#7913) -
[@&#8203;jordan-wong](https://github.com/jordan-wong))

##### Dynamic Instrumentation

- ✨ Add support for SymDB to scan directories
([#&#8203;8306](DataDog/dd-trace-java#8306) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- ✨ Add SymDB report for any jar scanning failures
([#&#8203;8300](DataDog/dd-trace-java#8300) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- ✨ Use two budgets depending on type
([#&#8203;8283](DataDog/dd-trace-java#8283) -
[@&#8203;evanchooly](https://github.com/evanchooly))
- ✨ Institute a 10 snapshot per probe per trace budget
([#&#8203;8277](DataDog/dd-trace-java#8277) -
[@&#8203;evanchooly](https://github.com/evanchooly))
- 🐛 Avoid double snapshots for Exception Replay
([#&#8203;8273](DataDog/dd-trace-java#8273) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- ✨ Simplify code origins. Separate out snapshot generation.
([#&#8203;8263](DataDog/dd-trace-java#8263) -
[@&#8203;evanchooly](https://github.com/evanchooly))
- ✨ Add Exception probe custom instrumentation
([#&#8203;8230](DataDog/dd-trace-java#8230) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- ✨ Enhance log probes to honor debug session tags
([#&#8203;8215](DataDog/dd-trace-java#8215) -
[@&#8203;evanchooly](https://github.com/evanchooly))
- 🐛 Don't redact env tokens from debugger probe snapshots
([#&#8203;8211](DataDog/dd-trace-java#8211) -
[@&#8203;watson](https://github.com/watson))
- ✨⚡ Move Trace/SpanId capture at commit time
([#&#8203;8184](DataDog/dd-trace-java#8184) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Capture values at entry for method probe
([#&#8203;8169](DataDog/dd-trace-java#8169) -
[@&#8203;jpbempel](https://github.com/jpbempel))

##### JMX fetch

- 🐛 Mute JMXFetch Shutdown in progress error
([#&#8203;8068](DataDog/dd-trace-java#8068) -
[@&#8203;ygree](https://github.com/ygree))

##### OpenTracing

- ⚠️🧹 Make jnr-unixsocket an explicit dependency of
dd-trace-ot
([#&#8203;8307](DataDog/dd-trace-java#8307) -
[@&#8203;mcculls](https://github.com/mcculls))

##### Profiling

- 🐛 Avoid unsupported API call for creating folders on windows
([#&#8203;8304](DataDog/dd-trace-java#8304) -
[@&#8203;jbachorik](https://github.com/jbachorik))
- ✨ Tag profiles for serverless
([#&#8203;8279](DataDog/dd-trace-java#8279) -
[@&#8203;jbachorik](https://github.com/jbachorik))
- ✨ add queue type and length to queue events
([#&#8203;8242](DataDog/dd-trace-java#8242) -
[@&#8203;richardstartin](https://github.com/richardstartin))
- 🐛 TempLocationManager Fixes and Improvements
([#&#8203;8191](DataDog/dd-trace-java#8191) -
[@&#8203;jbachorik](https://github.com/jbachorik))
- ✨ Bump ddprof to 1.18.0
([#&#8203;8173](DataDog/dd-trace-java#8173) -
[@&#8203;jbachorik](https://github.com/jbachorik))
- ✨ Report profiler initialization and configuration errors to
telemetry
([#&#8203;8171](DataDog/dd-trace-java#8171) -
[@&#8203;jbachorik](https://github.com/jbachorik))

##### Telemetry

- ✨ Add pending traces report in tracer flares
([#&#8203;8053](DataDog/dd-trace-java#8053) -
[@&#8203;mhlidd](https://github.com/mhlidd))

##### Testing

- ✨ Test http server requests in parallel
([#&#8203;8222](DataDog/dd-trace-java#8222) -
[@&#8203;amarziali](https://github.com/amarziali))

##### Trace context propagation

- ✨ Add non default propagator registration
([#&#8203;8310](DataDog/dd-trace-java#8310) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))

##### Tracer core

- ✨ Probe for existence of IBMSASL or ACCP security providers
([#&#8203;8276](DataDog/dd-trace-java#8276) -
[@&#8203;mcculls](https://github.com/mcculls))
- ✨⚡ Overhead improvement to agent feedback based sampling
([#&#8203;8265](DataDog/dd-trace-java#8265) -
[@&#8203;dougqh](https://github.com/dougqh))
- 🧹 Move async propagation API from scope to tracer
([#&#8203;8231](DataDog/dd-trace-java#8231) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
- ✨ Introduce context propagation API
([#&#8203;8161](DataDog/dd-trace-java#8161) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
- ✨🧪 Use env-entry to add tags per webapp deployment
([#&#8203;8138](DataDog/dd-trace-java#8138) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Introduce context helpers API
([#&#8203;8134](DataDog/dd-trace-java#8134) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
- ✨ Support IPv6 values for `DD_AGENT_HOST` and
`DD_TRACE_AGENT_URL`
([#&#8203;7984](DataDog/dd-trace-java#7984) -
[@&#8203;mhlidd](https://github.com/mhlidd))

##### Instrumentations

##### Apache HttpComponents

- 🐛 Properly finish spans and support latest apache httpclient5
([#&#8203;8272](DataDog/dd-trace-java#8272) -
[@&#8203;amarziali](https://github.com/amarziali))

##### AWS Lambda instrumentation

- 🐛 Properly capture lambda payloads for all handler types.
([#&#8203;8264](DataDog/dd-trace-java#8264) -
[@&#8203;purple4reina](https://github.com/purple4reina))

##### AWS S3 instrumentation

- 💡 Create S3 instrumentation + add span pointers
([#&#8203;8075](DataDog/dd-trace-java#8075) -
[@&#8203;nhulston](https://github.com/nhulston))

##### AWS SDK instrumentation

- 🐛 Revert "Add avoid double instrumenting lambda non-streaming
handlers."
([#&#8203;8247](DataDog/dd-trace-java#8247) -
[@&#8203;nhulston](https://github.com/nhulston))

##### Cassandra

- ✨ Allow extracting keyspace from statement result
([#&#8203;8239](DataDog/dd-trace-java#8239) -
[@&#8203;amarziali](https://github.com/amarziali))

##### Core Java language instrumentation

- ✨ Propagation of translateEscapes of String class
([#&#8203;8186](DataDog/dd-trace-java#8186) -
[@&#8203;sezen-datadog](https://github.com/sezen-datadog))

##### Eclipse Vert.x instrumentation

- 🐛 Fix vertx worker propagation and error handling
([#&#8203;8237](DataDog/dd-trace-java#8237) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Support vertx 5
([#&#8203;8220](DataDog/dd-trace-java#8220) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Add support for session tracking in Vertx
([#&#8203;8167](DataDog/dd-trace-java#8167) -
[@&#8203;manuel-alvarez-alvarez](https://github.com/manuel-alvarez-alvarez))

##### Kafka instrumentation

- 🐛 Prevent possible NPE calculating Kafka record header size
([#&#8203;8292](DataDog/dd-trace-java#8292) -
[@&#8203;ygree](https://github.com/ygree))

##### Mule instrumentation

- 🐛 Fix crash using Mule with JPMS
([#&#8203;8187](DataDog/dd-trace-java#8187) -
[@&#8203;amarziali](https://github.com/amarziali))

##### Protocol Buffer instrumentation

- ✨ Change hash computation for protobuf to better represent
impacting changes + save proto number in schema
([#&#8203;8201](DataDog/dd-trace-java#8201) -
[@&#8203;vandonr](https://github.com/vandonr))

##### Spring instrumentation

- 🐛 Preserve getQualifier from spring scheduling runnables
([#&#8203;8293](DataDog/dd-trace-java#8293) -
[@&#8203;amarziali](https://github.com/amarziali))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "after 6pm every weekday,before 2am
every weekday" in timezone Australia/Melbourne, Automerge - At any time
(no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get
[config help](https://github.com/renovatebot/renovate/discussions) if
that's undesired.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Renovate
Bot](https://github.com/renovatebot/renovate).

GitOrigin-RevId: bb09d47e4eed77a003f630273b4d0a84003eb899
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants