Skip to content

Conversation

@andrewlock
Copy link
Member

Summary of changes

Removes unused properties and functionality from MockTelemetryAgent

Reason for change

Noticed the obsolete behaviour while working on something else. The OptionalHeaders option was added as part of the original crashtracking work, and was partially removed as no longer required in #6835, and the parts here were just missed.

Implementation details

Delete unused code

Test coverage

As long as the tests still pass, we're good

Other details

Noticed while working on #8017

@andrewlock andrewlock added the type:cleanup Minor code clean up label Dec 30, 2025
@andrewlock andrewlock requested a review from a team as a code owner December 30, 2025 11:24
@github-actions github-actions bot added the area:tests unit tests, integration tests label Dec 30, 2025
@dd-trace-dotnet-ci-bot
Copy link

Execution-Time Benchmarks Report ⏱️

Execution-time results for samples comparing This PR (8020) and master.

✅ No regressions detected - check the details below

Full Metrics Comparison

FakeDbCommand

Metric Master (Mean ± 95% CI) Current (Mean ± 95% CI) Change Status
.NET Framework 4.8 - Baseline
duration68.16 ± (68.18 - 68.39) ms68.67 ± (68.71 - 68.97) ms+0.7%✅⬆️
.NET Framework 4.8 - Bailout
duration72.18 ± (72.02 - 72.30) ms72.47 ± (72.39 - 72.70) ms+0.4%✅⬆️
.NET Framework 4.8 - CallTarget+Inlining+NGEN
duration1004.61 ± (1008.90 - 1017.71) ms1004.75 ± (1006.37 - 1012.23) ms+0.0%✅⬆️
.NET Core 3.1 - Baseline
process.internal_duration_ms21.97 ± (21.93 - 22.01) ms21.93 ± (21.89 - 21.97) ms-0.2%
process.time_to_main_ms78.42 ± (78.26 - 78.57) ms79.08 ± (78.89 - 79.27) ms+0.8%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.90 ± (10.90 - 10.91) MB10.92 ± (10.92 - 10.93) MB+0.2%✅⬆️
runtime.dotnet.threads.count12 ± (12 - 12)12 ± (12 - 12)+0.0%
.NET Core 3.1 - Bailout
process.internal_duration_ms21.92 ± (21.90 - 21.94) ms22.01 ± (21.99 - 22.03) ms+0.4%✅⬆️
process.time_to_main_ms79.74 ± (79.65 - 79.84) ms80.27 ± (80.17 - 80.37) ms+0.7%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.95 ± (10.94 - 10.95) MB10.97 ± (10.97 - 10.98) MB+0.2%✅⬆️
runtime.dotnet.threads.count13 ± (13 - 13)13 ± (13 - 13)+0.0%
.NET Core 3.1 - CallTarget+Inlining+NGEN
process.internal_duration_ms241.58 ± (237.45 - 245.71) ms251.98 ± (248.67 - 255.29) ms+4.3%✅⬆️
process.time_to_main_ms469.82 ± (469.43 - 470.20) ms471.49 ± (470.96 - 472.02) ms+0.4%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed48.14 ± (48.12 - 48.16) MB48.27 ± (48.25 - 48.29) MB+0.3%✅⬆️
runtime.dotnet.threads.count28 ± (28 - 28)28 ± (28 - 28)+0.1%✅⬆️
.NET 6 - Baseline
process.internal_duration_ms20.61 ± (20.58 - 20.64) ms20.68 ± (20.65 - 20.70) ms+0.3%✅⬆️
process.time_to_main_ms67.90 ± (67.78 - 68.02) ms68.12 ± (68.03 - 68.21) ms+0.3%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.61 ± (10.61 - 10.61) MB10.65 ± (10.65 - 10.65) MB+0.4%✅⬆️
runtime.dotnet.threads.count10 ± (10 - 10)10 ± (10 - 10)+0.0%
.NET 6 - Bailout
process.internal_duration_ms20.52 ± (20.48 - 20.55) ms20.52 ± (20.50 - 20.55) ms+0.0%✅⬆️
process.time_to_main_ms68.72 ± (68.66 - 68.78) ms69.03 ± (68.99 - 69.08) ms+0.5%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.66 ± (10.66 - 10.67) MB10.76 ± (10.75 - 10.76) MB+0.9%✅⬆️
runtime.dotnet.threads.count11 ± (11 - 11)11 ± (11 - 11)+0.0%
.NET 6 - CallTarget+Inlining+NGEN
process.internal_duration_ms243.74 ± (241.62 - 245.86) ms246.52 ± (244.89 - 248.15) ms+1.1%✅⬆️
process.time_to_main_ms439.37 ± (438.95 - 439.79) ms441.14 ± (440.74 - 441.54) ms+0.4%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed48.69 ± (48.66 - 48.72) MB48.70 ± (48.67 - 48.74) MB+0.0%✅⬆️
runtime.dotnet.threads.count28 ± (28 - 28)28 ± (28 - 28)+0.1%✅⬆️
.NET 8 - Baseline
process.internal_duration_ms18.86 ± (18.83 - 18.89) ms18.88 ± (18.85 - 18.91) ms+0.1%✅⬆️
process.time_to_main_ms66.96 ± (66.86 - 67.07) ms67.21 ± (67.12 - 67.30) ms+0.4%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed7.67 ± (7.66 - 7.68) MB7.70 ± (7.69 - 7.70) MB+0.3%✅⬆️
runtime.dotnet.threads.count10 ± (10 - 10)10 ± (10 - 10)+0.0%
.NET 8 - Bailout
process.internal_duration_ms18.87 ± (18.84 - 18.89) ms18.83 ± (18.81 - 18.85) ms-0.2%
process.time_to_main_ms68.14 ± (68.09 - 68.20) ms68.21 ± (68.15 - 68.27) ms+0.1%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed7.73 ± (7.72 - 7.74) MB7.75 ± (7.74 - 7.76) MB+0.3%✅⬆️
runtime.dotnet.threads.count11 ± (11 - 11)11 ± (11 - 11)+0.0%
.NET 8 - CallTarget+Inlining+NGEN
process.internal_duration_ms179.43 ± (178.40 - 180.47) ms180.78 ± (179.80 - 181.77) ms+0.8%✅⬆️
process.time_to_main_ms426.67 ± (426.07 - 427.28) ms426.01 ± (425.33 - 426.70) ms-0.2%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed36.33 ± (36.30 - 36.36) MB36.35 ± (36.33 - 36.38) MB+0.1%✅⬆️
runtime.dotnet.threads.count27 ± (27 - 27)27 ± (27 - 27)-0.1%

HttpMessageHandler

Metric Master (Mean ± 95% CI) Current (Mean ± 95% CI) Change Status
.NET Framework 4.8 - Baseline
duration193.33 ± (193.49 - 194.38) ms193.88 ± (193.62 - 194.34) ms+0.3%✅⬆️
.NET Framework 4.8 - Bailout
duration196.51 ± (196.65 - 197.38) ms196.41 ± (196.25 - 196.77) ms-0.1%
.NET Framework 4.8 - CallTarget+Inlining+NGEN
duration1105.95 ± (1108.43 - 1116.17) ms1108.98 ± (1114.47 - 1123.69) ms+0.3%✅⬆️
.NET Core 3.1 - Baseline
process.internal_duration_ms187.65 ± (187.23 - 188.07) ms187.86 ± (187.52 - 188.20) ms+0.1%✅⬆️
process.time_to_main_ms80.43 ± (80.23 - 80.62) ms80.52 ± (80.32 - 80.73) ms+0.1%✅⬆️
runtime.dotnet.exceptions.count3 ± (3 - 3)3 ± (3 - 3)+0.0%
runtime.dotnet.mem.committed16.07 ± (16.04 - 16.10) MB16.06 ± (16.03 - 16.09) MB-0.0%
runtime.dotnet.threads.count20 ± (20 - 20)20 ± (20 - 20)+0.4%✅⬆️
.NET Core 3.1 - Bailout
process.internal_duration_ms187.09 ± (186.83 - 187.35) ms188.54 ± (188.16 - 188.92) ms+0.8%✅⬆️
process.time_to_main_ms81.80 ± (81.68 - 81.93) ms82.37 ± (82.19 - 82.55) ms+0.7%✅⬆️
runtime.dotnet.exceptions.count3 ± (3 - 3)3 ± (3 - 3)+0.0%
runtime.dotnet.mem.committed16.17 ± (16.14 - 16.19) MB16.13 ± (16.10 - 16.16) MB-0.2%
runtime.dotnet.threads.count21 ± (21 - 21)21 ± (21 - 21)-0.2%
.NET Core 3.1 - CallTarget+Inlining+NGEN
process.internal_duration_ms423.39 ± (420.21 - 426.57) ms427.27 ± (424.14 - 430.40) ms+0.9%✅⬆️
process.time_to_main_ms472.31 ± (471.64 - 472.97) ms474.42 ± (473.87 - 474.97) ms+0.4%✅⬆️
runtime.dotnet.exceptions.count3 ± (3 - 3)3 ± (3 - 3)+0.0%
runtime.dotnet.mem.committed58.81 ± (58.70 - 58.92) MB58.50 ± (58.39 - 58.60) MB-0.5%
runtime.dotnet.threads.count29 ± (29 - 30)29 ± (29 - 30)-0.0%
.NET 6 - Baseline
process.internal_duration_ms191.89 ± (191.51 - 192.28) ms191.83 ± (191.51 - 192.14) ms-0.0%
process.time_to_main_ms69.81 ± (69.67 - 69.95) ms69.71 ± (69.56 - 69.86) ms-0.1%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed16.28 ± (16.18 - 16.37) MB16.09 ± (15.94 - 16.24) MB-1.1%
runtime.dotnet.threads.count19 ± (19 - 19)18 ± (18 - 18)-3.6%
.NET 6 - Bailout
process.internal_duration_ms191.02 ± (190.79 - 191.25) ms191.36 ± (191.05 - 191.67) ms+0.2%✅⬆️
process.time_to_main_ms70.83 ± (70.72 - 70.93) ms70.88 ± (70.77 - 70.98) ms+0.1%✅⬆️
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed16.22 ± (16.08 - 16.35) MB16.24 ± (16.11 - 16.36) MB+0.1%✅⬆️
runtime.dotnet.threads.count19 ± (19 - 19)19 ± (19 - 19)+0.1%✅⬆️
.NET 6 - CallTarget+Inlining+NGEN
process.internal_duration_ms455.89 ± (454.05 - 457.74) ms455.17 ± (453.21 - 457.14) ms-0.2%
process.time_to_main_ms444.94 ± (444.42 - 445.46) ms444.82 ± (444.40 - 445.24) ms-0.0%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed58.42 ± (58.30 - 58.54) MB58.42 ± (58.30 - 58.54) MB+0.0%✅⬆️
runtime.dotnet.threads.count29 ± (29 - 30)30 ± (30 - 30)+0.2%✅⬆️
.NET 8 - Baseline
process.internal_duration_ms190.41 ± (190.01 - 190.81) ms190.62 ± (190.25 - 190.99) ms+0.1%✅⬆️
process.time_to_main_ms69.42 ± (69.24 - 69.59) ms69.72 ± (69.52 - 69.93) ms+0.4%✅⬆️
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed11.78 ± (11.75 - 11.81) MB11.72 ± (11.69 - 11.74) MB-0.5%
runtime.dotnet.threads.count18 ± (18 - 18)18 ± (18 - 18)-0.2%
.NET 8 - Bailout
process.internal_duration_ms189.67 ± (189.39 - 189.96) ms189.27 ± (189.03 - 189.50) ms-0.2%
process.time_to_main_ms70.53 ± (70.39 - 70.67) ms70.43 ± (70.32 - 70.53) ms-0.2%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed11.81 ± (11.78 - 11.84) MB11.78 ± (11.75 - 11.81) MB-0.2%
runtime.dotnet.threads.count19 ± (19 - 19)19 ± (19 - 19)+0.3%✅⬆️
.NET 8 - CallTarget+Inlining+NGEN
process.internal_duration_ms362.18 ± (360.73 - 363.63) ms361.50 ± (359.92 - 363.07) ms-0.2%
process.time_to_main_ms428.11 ± (427.57 - 428.66) ms430.96 ± (430.25 - 431.68) ms+0.7%✅⬆️
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed47.95 ± (47.92 - 47.98) MB47.95 ± (47.91 - 47.98) MB-0.0%
runtime.dotnet.threads.count29 ± (29 - 29)29 ± (29 - 29)+0.2%✅⬆️
Comparison explanation

Execution-time benchmarks measure the whole time it takes to execute a program, and are intended to measure the one-off costs. Cases where the execution time results for the PR are worse than latest master results are highlighted in **red**. The following thresholds were used for comparing the execution times:

  • Welch test with statistical test for significance of 5%
  • Only results indicating a difference greater than 5% and 5 ms are considered.

Note that these results are based on a single point-in-time result for each branch. For full results, see the dashboard.

Graphs show the p99 interval based on the mean and StdDev of the test run, as well as the mean value of the run (shown as a diamond below the graph).

Duration charts
FakeDbCommand (.NET Framework 4.8)
gantt
    title Execution time (ms) FakeDbCommand (.NET Framework 4.8)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (69ms)  : 67, 71
    master - mean (68ms)  : 67, 70

    section Bailout
    This PR (8020) - mean (73ms)  : 71, 74
    master - mean (72ms)  : 71, 74

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (1,009ms)  : 968, 1051
    master - mean (1,013ms)  : 948, 1078

Loading
FakeDbCommand (.NET Core 3.1)
gantt
    title Execution time (ms) FakeDbCommand (.NET Core 3.1)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (106ms)  : 104, 109
    master - mean (105ms)  : 103, 108

    section Bailout
    This PR (8020) - mean (107ms)  : 106, 109
    master - mean (107ms)  : 105, 108

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (747ms)  : 694, 800
    master - mean (735ms)  : 667, 804

Loading
FakeDbCommand (.NET 6)
gantt
    title Execution time (ms) FakeDbCommand (.NET 6)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (93ms)  : 91, 95
    master - mean (93ms)  : 91, 95

    section Bailout
    This PR (8020) - mean (94ms)  : 93, 95
    master - mean (94ms)  : 93, 95

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (713ms)  : 684, 741
    master - mean (708ms)  : 671, 745

Loading
FakeDbCommand (.NET 8)
gantt
    title Execution time (ms) FakeDbCommand (.NET 8)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (92ms)  : 90, 94
    master - mean (92ms)  : 90, 94

    section Bailout
    This PR (8020) - mean (93ms)  : 92, 95
    master - mean (93ms)  : 92, 94

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (634ms)  : 617, 650
    master - mean (634ms)  : 617, 650

Loading
HttpMessageHandler (.NET Framework 4.8)
gantt
    title Execution time (ms) HttpMessageHandler (.NET Framework 4.8)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (194ms)  : 191, 197
    master - mean (194ms)  : 190, 198

    section Bailout
    This PR (8020) - mean (197ms)  : 194, 199
    master - mean (197ms)  : 193, 201

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (1,119ms)  : 1054, 1185
    master - mean (1,112ms)  : 1054, 1170

Loading
HttpMessageHandler (.NET Core 3.1)
gantt
    title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (277ms)  : 271, 283
    master - mean (276ms)  : 272, 281

    section Bailout
    This PR (8020) - mean (279ms)  : 273, 285
    master - mean (277ms)  : 274, 280

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (931ms)  : 890, 972
    master - mean (925ms)  : 883, 967

Loading
HttpMessageHandler (.NET 6)
gantt
    title Execution time (ms) HttpMessageHandler (.NET 6)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (270ms)  : 265, 275
    master - mean (270ms)  : 266, 274

    section Bailout
    This PR (8020) - mean (270ms)  : 266, 274
    master - mean (270ms)  : 267, 273

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (927ms)  : 883, 971
    master - mean (931ms)  : 898, 964

Loading
HttpMessageHandler (.NET 8)
gantt
    title Execution time (ms) HttpMessageHandler (.NET 8)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (8020) - mean (270ms)  : 265, 275
    master - mean (269ms)  : 264, 275

    section Bailout
    This PR (8020) - mean (269ms)  : 266, 272
    master - mean (270ms)  : 266, 274

    section CallTarget+Inlining+NGEN
    This PR (8020) - mean (823ms)  : 804, 841
    master - mean (822ms)  : 807, 837

Loading

@datadog-datadog-prod-us1
Copy link

datadog-datadog-prod-us1 bot commented Dec 30, 2025

⚠️ Tests

Fix all issues with Cursor

⚠️ Warnings

❄️ 1 New flaky test detected

RunTest from Datadog.Trace.Security.IntegrationTests.Rcm.AspNetCore5AsmDataSecurityEnabledBlockingUser (Datadog) (Fix with Cursor)
Unable to determine port application is listening on

ℹ️ Info

🧪 All tests passed

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 7ade4e5 | Docs | Datadog PR Page | Was this helpful? Give us feedback!

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

Labels

area:tests unit tests, integration tests type:cleanup Minor code clean up

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants