Skip to content

Conversation

@lucaspimentel
Copy link
Member

@lucaspimentel lucaspimentel commented Oct 3, 2025

Summary

Adds DD_AGENT_FEATURE_POLLING_ENABLED environment variable (default: true) to allow disabling the agent discovery service. When disabled, the tracer uses NullDiscoveryService instead of querying the agent for available endpoints.

Motivation

In certain environments, such as Azure Functions with the Rust agent, the discovery endpoint is not available. Currently, the tracer always attempts to query the discovery service, which results in unnecessary network calls and potential errors in these scenarios.

Changes

  • Added DD_AGENT_FEATURE_POLLING_ENABLED configuration key to ConfigurationKeys.cs
  • Added AgentFeaturePollingEnabled property to TracerSettings (defaults to true)
  • Updated TracerManagerFactory.GetDiscoveryService() to return NullDiscoveryService.Instance when disabled
  • Changed GetDiscoveryService() visibility from protected to internal virtual for consistency with override in TestOptimizationTracerManagerFactory
  • Added unit test DiscoveryServiceCanBeDisabled to verify both enabled and disabled states

Test Plan

  • Unit test verifies setting is read correctly
  • Unit test verifies DiscoveryService is returned when enabled
  • Unit test verifies NullDiscoveryService.Instance is returned when disabled
  • Manual testing in Azure Functions environment with Rust agent

🤖 Generated with Claude Code

@datadog-datadog-prod-us1

This comment has been minimized.

@dd-trace-dotnet-ci-bot
Copy link

dd-trace-dotnet-ci-bot bot commented Oct 3, 2025

Execution-Time Benchmarks Report ⏱️

Execution-time results for samples comparing This PR (7616) 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
duration76.42 ± (76.47 - 77.11) ms74.09 ± (74.14 - 74.69) ms-3.1%
.NET Framework 4.8 - Bailout
duration79.98 ± (79.99 - 80.55) ms80.70 ± (80.46 - 81.16) ms+0.9%✅⬆️
.NET Framework 4.8 - CallTarget+Inlining+NGEN
duration1126.98 ± (1126.34 - 1136.62) ms1103.41 ± (1106.10 - 1115.46) ms-2.1%
.NET Core 3.1 - Baseline
process.internal_duration_ms23.19 ± (23.11 - 23.27) ms23.15 ± (23.06 - 23.23) ms-0.2%
process.time_to_main_ms89.22 ± (88.88 - 89.55) ms87.94 ± (87.58 - 88.30) ms-1.4%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.93 ± (10.93 - 10.94) MB10.92 ± (10.92 - 10.93) MB-0.1%
runtime.dotnet.threads.count12 ± (12 - 12)12 ± (12 - 12)+0.0%
.NET Core 3.1 - Bailout
process.internal_duration_ms22.96 ± (22.91 - 23.01) ms22.86 ± (22.80 - 22.93) ms-0.4%
process.time_to_main_ms89.56 ± (89.26 - 89.86) ms88.29 ± (87.94 - 88.64) ms-1.4%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.97 ± (10.97 - 10.98) MB10.94 ± (10.94 - 10.94) MB-0.3%
runtime.dotnet.threads.count13 ± (13 - 13)13 ± (13 - 13)+0.0%
.NET Core 3.1 - CallTarget+Inlining+NGEN
process.internal_duration_ms219.83 ± (218.31 - 221.35) ms221.92 ± (220.67 - 223.17) ms+1.0%✅⬆️
process.time_to_main_ms551.56 ± (550.30 - 552.83) ms544.62 ± (543.45 - 545.78) ms-1.3%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed52.52 ± (52.50 - 52.54) MB52.40 ± (52.38 - 52.42) MB-0.2%
runtime.dotnet.threads.count28 ± (28 - 28)28 ± (28 - 28)+0.6%✅⬆️
.NET 6 - Baseline
process.internal_duration_ms21.73 ± (21.65 - 21.80) ms21.61 ± (21.55 - 21.67) ms-0.5%
process.time_to_main_ms75.62 ± (75.29 - 75.96) ms74.69 ± (74.38 - 75.01) ms-1.2%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.62 ± (10.62 - 10.62) MB10.62 ± (10.62 - 10.62) MB-0.0%
runtime.dotnet.threads.count10 ± (10 - 10)10 ± (10 - 10)+0.0%
.NET 6 - Bailout
process.internal_duration_ms21.94 ± (21.88 - 22.00) ms21.67 ± (21.62 - 21.73) ms-1.2%
process.time_to_main_ms78.28 ± (77.92 - 78.63) ms76.10 ± (75.80 - 76.39) ms-2.8%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed10.67 ± (10.67 - 10.67) MB10.65 ± (10.65 - 10.65) MB-0.2%
runtime.dotnet.threads.count11 ± (11 - 11)11 ± (11 - 11)+0.0%
.NET 6 - CallTarget+Inlining+NGEN
process.internal_duration_ms206.49 ± (205.15 - 207.82) ms207.67 ± (206.20 - 209.14) ms+0.6%✅⬆️
process.time_to_main_ms514.95 ± (513.89 - 516.01) ms512.26 ± (511.12 - 513.40) ms-0.5%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed51.70 ± (51.67 - 51.73) MB51.46 ± (51.43 - 51.49) MB-0.5%
runtime.dotnet.threads.count28 ± (28 - 28)28 ± (28 - 28)+0.0%✅⬆️
.NET 8 - Baseline
process.internal_duration_ms19.96 ± (19.89 - 20.03) ms19.82 ± (19.76 - 19.87) ms-0.7%
process.time_to_main_ms75.65 ± (75.30 - 75.99) ms74.15 ± (73.86 - 74.44) ms-2.0%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed7.67 ± (7.66 - 7.67) MB7.65 ± (7.64 - 7.66) MB-0.3%
runtime.dotnet.threads.count10 ± (10 - 10)10 ± (10 - 10)+0.0%
.NET 8 - Bailout
process.internal_duration_ms19.71 ± (19.66 - 19.77) ms19.93 ± (19.88 - 19.98) ms+1.1%✅⬆️
process.time_to_main_ms75.97 ± (75.67 - 76.26) ms76.42 ± (76.12 - 76.73) ms+0.6%✅⬆️
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed7.72 ± (7.72 - 7.73) MB7.68 ± (7.67 - 7.68) MB-0.6%
runtime.dotnet.threads.count11 ± (11 - 11)11 ± (11 - 11)+0.0%
.NET 8 - CallTarget+Inlining+NGEN
process.internal_duration_ms188.07 ± (187.13 - 189.01) ms190.76 ± (189.95 - 191.58) ms+1.4%✅⬆️
process.time_to_main_ms485.80 ± (484.88 - 486.72) ms481.85 ± (480.93 - 482.77) ms-0.8%
runtime.dotnet.exceptions.count0 ± (0 - 0)0 ± (0 - 0)+0.0%
runtime.dotnet.mem.committed38.78 ± (38.75 - 38.82) MB38.62 ± (38.59 - 38.66) MB-0.4%
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.47 ± (193.37 - 194.33) ms192.68 ± (192.58 - 193.44) ms-0.4%
.NET Framework 4.8 - Bailout
duration196.52 ± (196.51 - 197.13) ms196.43 ± (196.30 - 196.91) ms-0.0%
.NET Framework 4.8 - CallTarget+Inlining+NGEN
duration1170.27 ± (1170.50 - 1178.78) ms1161.01 ± (1162.57 - 1170.69) ms-0.8%
.NET Core 3.1 - Baseline
process.internal_duration_ms187.61 ± (187.20 - 188.01) ms187.89 ± (187.53 - 188.25) ms+0.2%✅⬆️
process.time_to_main_ms81.41 ± (81.16 - 81.66) ms80.37 ± (80.16 - 80.59) ms-1.3%
runtime.dotnet.exceptions.count3 ± (3 - 3)3 ± (3 - 3)+0.0%
runtime.dotnet.mem.committed16.05 ± (16.02 - 16.07) MB16.14 ± (16.11 - 16.16) MB+0.6%✅⬆️
runtime.dotnet.threads.count20 ± (20 - 20)20 ± (20 - 20)-0.3%
.NET Core 3.1 - Bailout
process.internal_duration_ms187.02 ± (186.75 - 187.28) ms187.67 ± (187.26 - 188.07) ms+0.3%✅⬆️
process.time_to_main_ms82.29 ± (82.12 - 82.46) ms81.86 ± (81.68 - 82.05) ms-0.5%
runtime.dotnet.exceptions.count3 ± (3 - 3)3 ± (3 - 3)+0.0%
runtime.dotnet.mem.committed16.12 ± (16.10 - 16.15) MB16.22 ± (16.20 - 16.25) MB+0.6%✅⬆️
runtime.dotnet.threads.count21 ± (20 - 21)21 ± (21 - 21)+0.6%✅⬆️
.NET Core 3.1 - CallTarget+Inlining+NGEN
process.internal_duration_ms398.28 ± (395.42 - 401.14) ms394.25 ± (391.84 - 396.67) ms-1.0%
process.time_to_main_ms522.59 ± (521.66 - 523.51) ms514.73 ± (514.09 - 515.37) ms-1.5%
runtime.dotnet.exceptions.count3 ± (3 - 3)3 ± (3 - 3)+0.0%
runtime.dotnet.mem.committed62.80 ± (62.65 - 62.96) MB62.85 ± (62.68 - 63.02) MB+0.1%✅⬆️
runtime.dotnet.threads.count29 ± (29 - 29)29 ± (29 - 29)+0.0%✅⬆️
.NET 6 - Baseline
process.internal_duration_ms192.77 ± (192.38 - 193.16) ms191.74 ± (191.44 - 192.04) ms-0.5%
process.time_to_main_ms70.10 ± (69.91 - 70.29) ms69.93 ± (69.75 - 70.10) ms-0.2%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed16.07 ± (15.94 - 16.21) MB16.12 ± (15.99 - 16.25) MB+0.3%✅⬆️
runtime.dotnet.threads.count18 ± (18 - 18)18 ± (18 - 19)+0.3%✅⬆️
.NET 6 - Bailout
process.internal_duration_ms191.05 ± (190.79 - 191.31) ms192.08 ± (191.76 - 192.41) ms+0.5%✅⬆️
process.time_to_main_ms70.75 ± (70.65 - 70.86) ms71.09 ± (70.91 - 71.26) ms+0.5%✅⬆️
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed16.03 ± (15.88 - 16.17) MB16.13 ± (16.00 - 16.26) MB+0.7%✅⬆️
runtime.dotnet.threads.count19 ± (19 - 19)20 ± (19 - 20)+3.1%✅⬆️
.NET 6 - CallTarget+Inlining+NGEN
process.internal_duration_ms411.24 ± (408.15 - 414.32) ms414.27 ± (411.12 - 417.41) ms+0.7%✅⬆️
process.time_to_main_ms488.56 ± (488.02 - 489.11) ms485.30 ± (484.68 - 485.91) ms-0.7%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed61.95 ± (61.80 - 62.09) MB61.79 ± (61.64 - 61.94) MB-0.3%
runtime.dotnet.threads.count29 ± (29 - 29)29 ± (29 - 30)+0.2%✅⬆️
.NET 8 - Baseline
process.internal_duration_ms190.45 ± (190.01 - 190.88) ms189.61 ± (189.34 - 189.88) ms-0.4%
process.time_to_main_ms69.26 ± (69.10 - 69.41) ms69.10 ± (68.94 - 69.26) ms-0.2%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed11.70 ± (11.68 - 11.73) MB11.69 ± (11.64 - 11.73) MB-0.1%
runtime.dotnet.threads.count18 ± (18 - 18)18 ± (18 - 18)-0.8%
.NET 8 - Bailout
process.internal_duration_ms189.41 ± (189.16 - 189.66) ms189.72 ± (189.40 - 190.04) ms+0.2%✅⬆️
process.time_to_main_ms70.30 ± (70.20 - 70.40) ms70.27 ± (70.15 - 70.38) ms-0.0%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed11.79 ± (11.76 - 11.82) MB11.80 ± (11.77 - 11.82) MB+0.1%✅⬆️
runtime.dotnet.threads.count19 ± (19 - 19)19 ± (19 - 19)+0.4%✅⬆️
.NET 8 - CallTarget+Inlining+NGEN
process.internal_duration_ms363.53 ± (362.04 - 365.02) ms356.91 ± (355.65 - 358.17) ms-1.8%
process.time_to_main_ms465.37 ± (464.67 - 466.08) ms457.83 ± (457.21 - 458.46) ms-1.6%
runtime.dotnet.exceptions.count4 ± (4 - 4)4 ± (4 - 4)+0.0%
runtime.dotnet.mem.committed50.22 ± (50.18 - 50.26) MB50.08 ± (50.05 - 50.12) MB-0.3%
runtime.dotnet.threads.count29 ± (29 - 29)29 ± (29 - 29)+0.4%✅⬆️
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 (7616) - mean (74ms)  : 71, 78
    master - mean (77ms)  : 72, 82

    section Bailout
    This PR (7616) - mean (81ms)  : 76, 86
    master - mean (80ms)  : 76, 84

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (1,111ms)  : 1044, 1177
    master - mean (1,131ms)  : 1058, 1205

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 (7616) - mean (119ms)  : 112, 125
    master - mean (120ms)  : 114, 126

    section Bailout
    This PR (7616) - mean (119ms)  : 111, 126
    master - mean (120ms)  : 115, 126

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (806ms)  : 762, 851
    master - mean (819ms)  : 765, 873

Loading
FakeDbCommand (.NET 6)
gantt
    title Execution time (ms) FakeDbCommand (.NET 6)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (7616) - mean (103ms)  : 97, 109
    master - mean (105ms)  : 98, 112

    section Bailout
    This PR (7616) - mean (105ms)  : 99, 110
    master - mean (108ms)  : 100, 115

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (753ms)  : 711, 795
    master - mean (767ms)  : 724, 810

Loading
FakeDbCommand (.NET 8)
gantt
    title Execution time (ms) FakeDbCommand (.NET 8)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (7616) - mean (102ms)  : 97, 107
    master - mean (104ms)  : 98, 110

    section Bailout
    This PR (7616) - mean (105ms)  : 98, 111
    master - mean (104ms)  : 97, 111

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (707ms)  : 675, 739
    master - mean (717ms)  : 686, 747

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 (7616) - mean (193ms)  : 189, 197
    master - mean (194ms)  : 189, 199

    section Bailout
    This PR (7616) - mean (197ms)  : 194, 200
    master - mean (197ms)  : 194, 200

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (1,167ms)  : 1108, 1225
    master - mean (1,175ms)  : 1116, 1234

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 (7616) - mean (276ms)  : 271, 282
    master - mean (277ms)  : 271, 284

    section Bailout
    This PR (7616) - mean (278ms)  : 272, 284
    master - mean (278ms)  : 274, 282

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (943ms)  : 896, 990
    master - mean (964ms)  : 914, 1014

Loading
HttpMessageHandler (.NET 6)
gantt
    title Execution time (ms) HttpMessageHandler (.NET 6)
    dateFormat  x
    axisFormat %Q
    todayMarker off
    section Baseline
    This PR (7616) - mean (269ms)  : 266, 273
    master - mean (271ms)  : 266, 276

    section Bailout
    This PR (7616) - mean (272ms)  : 265, 278
    master - mean (270ms)  : 266, 274

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (935ms)  : 879, 991
    master - mean (934ms)  : 880, 988

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

    section Bailout
    This PR (7616) - mean (269ms)  : 264, 275
    master - mean (269ms)  : 266, 272

    section CallTarget+Inlining+NGEN
    This PR (7616) - mean (848ms)  : 830, 865
    master - mean (860ms)  : 843, 878

Loading

@lucaspimentel lucaspimentel marked this pull request as ready for review October 3, 2025 22:13
@lucaspimentel lucaspimentel requested review from a team as code owners October 3, 2025 22:13
@lucaspimentel lucaspimentel changed the title Add configuration option to disable agent discovery service [config] Add DD_DISCOVERY_SERVICE_ENABLED to disable agent discovery service Oct 8, 2025
@lucaspimentel lucaspimentel changed the title [config] Add DD_DISCOVERY_SERVICE_ENABLED to disable agent discovery service [config] Add DD_DISCOVERY_SERVICE_ENABLED setting Oct 9, 2025
@lucaspimentel lucaspimentel force-pushed the lpimentel/disable-discovery-service branch from 7ac24dd to 252a234 Compare October 10, 2025 19:23
@lucaspimentel
Copy link
Member Author

lucaspimentel commented Oct 20, 2025

dd-trace-java went with DD_TRACE_SERVICE_DISCOVERY_ENABLED.
See DataDog/dd-trace-java#9705.

Sorry, different feature. "Service discovery" vs "discovery service". I changed the name to DD_AGENT_FEATURE_POLLING_ENABLED to avoid confusion.

@mcculls
Copy link

mcculls commented Oct 21, 2025

dd-trace-java went with DD_TRACE_SERVICE_DISCOVERY_ENABLED.
See DataDog/dd-trace-java#9705.

we can change it to DD_SERVICE_DISCOVERY_ENABLED in dd-trace-java if we want to align on that name

@lucaspimentel lucaspimentel force-pushed the lpimentel/disable-discovery-service branch from 5ab8f99 to 2fbfdd1 Compare October 21, 2025 17:58
@pr-commenter
Copy link

pr-commenter bot commented Oct 21, 2025

Benchmarks

Benchmarks Report for benchmark platform 🐌

Benchmarks for #7616 compared to master:

  • 1 benchmarks are faster, with geometric mean 1.144
  • 2 benchmarks are slower, with geometric mean 1.535
  • 2 benchmarks have fewer allocations
  • 5 benchmarks have more allocations

The following thresholds were used for comparing the benchmark speeds:

  • Mann–Whitney U test with statistical test for significance of 5%
  • Only results indicating a difference greater than 10% and 0.3 ns are considered.

Allocation changes below 0.5% are ignored.

Benchmark details

Benchmarks.Trace.ActivityBenchmark - Same speed ✔️ More allocations ⚠️

More allocations ⚠️ in #7616

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.ActivityBenchmark.StartStopWithChild‑net472 5.99 KB 6.09 KB 97 B 1.62%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartStopWithChild net6.0 10.4μs 58.1ns 394ns 0 0 0 5.51 KB
master StartStopWithChild netcoreapp3.1 13.6μs 67.3ns 293ns 0 0 0 5.73 KB
master StartStopWithChild net472 21.7μs 116ns 612ns 1.01 0.405 0.101 5.99 KB
#7616 StartStopWithChild net6.0 10.6μs 57.8ns 352ns 0 0 0 5.52 KB
#7616 StartStopWithChild netcoreapp3.1 14.3μs 66ns 264ns 0 0 0 5.73 KB
#7616 StartStopWithChild net472 22.8μs 117ns 641ns 0.947 0.237 0 6.09 KB
Benchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7616

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.AgentWriterBenchmark.WriteAndFlushEnrichedTraces‑net472 3.35 KB 3.31 KB -46 B -1.37%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master WriteAndFlushEnrichedTraces net6.0 949μs 244ns 947ns 0 0 0 2.71 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 1.03ms 205ns 795ns 0 0 0 2.7 KB
master WriteAndFlushEnrichedTraces net472 1.22ms 1.26μs 4.89μs 0 0 0 3.35 KB
#7616 WriteAndFlushEnrichedTraces net6.0 925μs 166ns 622ns 0 0 0 2.71 KB
#7616 WriteAndFlushEnrichedTraces netcoreapp3.1 1.02ms 320ns 1.24μs 0 0 0 2.7 KB
#7616 WriteAndFlushEnrichedTraces net472 1.2ms 485ns 1.68μs 0 0 0 3.31 KB
Benchmarks.Trace.Asm.AppSecBodyBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master AllCycleSimpleBody net6.0 1.07μs 6.16ns 39.4ns 0 0 0 1.22 KB
master AllCycleSimpleBody netcoreapp3.1 1.44μs 7.63ns 37.4ns 0 0 0 1.2 KB
master AllCycleSimpleBody net472 1.02μs 0.441ns 1.65ns 0.193 0 0 1.23 KB
master AllCycleMoreComplexBody net6.0 7.12μs 33.7ns 135ns 0 0 0 4.72 KB
master AllCycleMoreComplexBody netcoreapp3.1 9.24μs 10.5ns 40.8ns 0 0 0 4.62 KB
master AllCycleMoreComplexBody net472 7.56μs 5.55ns 21.5ns 0.718 0 0 4.74 KB
master ObjectExtractorSimpleBody net6.0 313ns 1.68ns 9.52ns 0 0 0 280 B
master ObjectExtractorSimpleBody netcoreapp3.1 403ns 1.94ns 8.23ns 0 0 0 272 B
master ObjectExtractorSimpleBody net472 295ns 0.0319ns 0.12ns 0.0432 0 0 281 B
master ObjectExtractorMoreComplexBody net6.0 6.39μs 28.9ns 108ns 0 0 0 3.78 KB
master ObjectExtractorMoreComplexBody netcoreapp3.1 7.78μs 35.9ns 139ns 0 0 0 3.69 KB
master ObjectExtractorMoreComplexBody net472 6.7μs 3.35ns 12.5ns 0.6 0 0 3.8 KB
#7616 AllCycleSimpleBody net6.0 1.08μs 5.5ns 26.4ns 0 0 0 1.22 KB
#7616 AllCycleSimpleBody netcoreapp3.1 1.4μs 0.757ns 2.83ns 0 0 0 1.2 KB
#7616 AllCycleSimpleBody net472 1.02μs 1.44ns 5.37ns 0.193 0 0 1.23 KB
#7616 AllCycleMoreComplexBody net6.0 7.03μs 37ns 192ns 0 0 0 4.72 KB
#7616 AllCycleMoreComplexBody netcoreapp3.1 9.17μs 4.03ns 15.6ns 0 0 0 4.62 KB
#7616 AllCycleMoreComplexBody net472 7.68μs 3.16ns 12.2ns 0.729 0 0 4.74 KB
#7616 ObjectExtractorSimpleBody net6.0 324ns 1.68ns 8.05ns 0 0 0 280 B
#7616 ObjectExtractorSimpleBody netcoreapp3.1 404ns 2.04ns 9.36ns 0 0 0 272 B
#7616 ObjectExtractorSimpleBody net472 296ns 0.0179ns 0.0671ns 0.0432 0 0 281 B
#7616 ObjectExtractorMoreComplexBody net6.0 6.33μs 1.65ns 6.38ns 0 0 0 3.78 KB
#7616 ObjectExtractorMoreComplexBody netcoreapp3.1 7.77μs 37.5ns 150ns 0 0 0 3.69 KB
#7616 ObjectExtractorMoreComplexBody net472 6.73μs 2.68ns 10.4ns 0.571 0 0 3.8 KB
Benchmarks.Trace.Asm.AppSecEncoderBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EncodeArgs net6.0 77.6μs 108ns 418ns 0 0 0 32.4 KB
master EncodeArgs netcoreapp3.1 97.2μs 335ns 1.3μs 0 0 0 32.4 KB
master EncodeArgs net472 110μs 39.9ns 144ns 4.99 0 0 32.51 KB
master EncodeLegacyArgs net6.0 145μs 20.3ns 78.5ns 0 0 0 2.15 KB
master EncodeLegacyArgs netcoreapp3.1 199μs 281ns 1.09μs 0 0 0 2.14 KB
master EncodeLegacyArgs net472 262μs 65.8ns 255ns 0 0 0 2.16 KB
#7616 EncodeArgs net6.0 77.4μs 251ns 974ns 0 0 0 32.4 KB
#7616 EncodeArgs netcoreapp3.1 97.1μs 49.9ns 193ns 0 0 0 32.4 KB
#7616 EncodeArgs net472 110μs 183ns 710ns 5.03 0 0 32.51 KB
#7616 EncodeLegacyArgs net6.0 143μs 36.6ns 142ns 0 0 0 2.15 KB
#7616 EncodeLegacyArgs netcoreapp3.1 198μs 101ns 379ns 0 0 0 2.14 KB
#7616 EncodeLegacyArgs net472 265μs 41.8ns 162ns 0 0 0 2.16 KB
Benchmarks.Trace.Asm.AppSecWafBenchmark - Slower ⚠️ Same allocations ✔️

Slower ⚠️ in #7616

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.Asm.AppSecWafBenchmark.RunWafRealisticBenchmark‑netcoreapp3.1 2.085 409,719.46 854,124.58

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master RunWafRealisticBenchmark net6.0 401μs 24.7ns 92.4ns 0 0 0 4.56 KB
master RunWafRealisticBenchmark netcoreapp3.1 410μs 61.6ns 230ns 0 0 0 4.48 KB
master RunWafRealisticBenchmark net472 429μs 66.2ns 256ns 0 0 0 4.66 KB
master RunWafRealisticBenchmarkWithAttack net6.0 284μs 38.6ns 144ns 0 0 0 2.24 KB
master RunWafRealisticBenchmarkWithAttack netcoreapp3.1 296μs 157ns 610ns 0 0 0 2.22 KB
master RunWafRealisticBenchmarkWithAttack net472 315μs 19.3ns 69.4ns 0 0 0 2.29 KB
#7616 RunWafRealisticBenchmark net6.0 394μs 162ns 604ns 0 0 0 4.56 KB
#7616 RunWafRealisticBenchmark netcoreapp3.1 850μs 3.88μs 15.5μs 0 0 0 4.48 KB
#7616 RunWafRealisticBenchmark net472 429μs 44.4ns 160ns 0 0 0 4.66 KB
#7616 RunWafRealisticBenchmarkWithAttack net6.0 286μs 60.7ns 227ns 0 0 0 2.24 KB
#7616 RunWafRealisticBenchmarkWithAttack netcoreapp3.1 297μs 144ns 540ns 0 0 0 2.22 KB
#7616 RunWafRealisticBenchmarkWithAttack net472 311μs 12.4ns 42.9ns 0 0 0 2.29 KB
Benchmarks.Trace.AspNetCoreBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master SendRequest net6.0 61.2μs 283ns 1.36μs 0 0 0 14.52 KB
master SendRequest netcoreapp3.1 72.9μs 214ns 801ns 0 0 0 17.42 KB
master SendRequest net472 0.00499ns 0.0018ns 0.00698ns 0 0 0 0 b
#7616 SendRequest net6.0 61.4μs 67.8ns 263ns 0 0 0 14.52 KB
#7616 SendRequest netcoreapp3.1 70.2μs 124ns 465ns 0 0 0 17.42 KB
#7616 SendRequest net472 0.00155ns 0.000765ns 0.00296ns 0 0 0 0 b
Benchmarks.Trace.CharSliceBenchmark - Slower ⚠️ More allocations ⚠️

Slower ⚠️ in #7616

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.CharSliceBenchmark.OptimizedCharSliceWithPool‑net6.0 1.130 831,326.04 939,072.40

More allocations ⚠️ in #7616

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.CharSliceBenchmark.OptimizedCharSliceWithPool‑netcoreapp3.1 0 b 1 B 1 B
Benchmarks.Trace.CharSliceBenchmark.OptimizedCharSlice‑net6.0 4 B 8 B 4 B 100.00%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master OriginalCharSlice net6.0 1.91ms 1.31μs 5.06μs 0 0 0 640.01 KB
master OriginalCharSlice netcoreapp3.1 2.12ms 5.72μs 22.2μs 0 0 0 640 KB
master OriginalCharSlice net472 2.56ms 918ns 3.44μs 100 0 0 641.95 KB
master OptimizedCharSlice net6.0 1.45ms 526ns 2.04μs 0 0 0 4 B
master OptimizedCharSlice netcoreapp3.1 1.77ms 718ns 2.78μs 0 0 0 1 B
master OptimizedCharSlice net472 2ms 315ns 1.22μs 0 0 0 0 b
master OptimizedCharSliceWithPool net6.0 831μs 22.4ns 83.8ns 0 0 0 3 B
master OptimizedCharSliceWithPool netcoreapp3.1 811μs 76.3ns 296ns 0 0 0 0 b
master OptimizedCharSliceWithPool net472 1.13ms 120ns 466ns 0 0 0 0 b
#7616 OriginalCharSlice net6.0 1.91ms 6.26μs 24.3μs 0 0 0 640.01 KB
#7616 OriginalCharSlice netcoreapp3.1 2.19ms 8.87μs 32μs 0 0 0 640 KB
#7616 OriginalCharSlice net472 2.72ms 633ns 2.45μs 100 0 0 641.95 KB
#7616 OptimizedCharSlice net6.0 1.58ms 1.11μs 4.28μs 0 0 0 8 B
#7616 OptimizedCharSlice netcoreapp3.1 1.79ms 318ns 1.15μs 0 0 0 1 B
#7616 OptimizedCharSlice net472 2ms 361ns 1.4μs 0 0 0 0 b
#7616 OptimizedCharSliceWithPool net6.0 939μs 54ns 209ns 0 0 0 3 B
#7616 OptimizedCharSliceWithPool netcoreapp3.1 846μs 94ns 364ns 0 0 0 1 B
#7616 OptimizedCharSliceWithPool net472 1.16ms 139ns 521ns 0 0 0 0 b
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark - Faster 🎉 Same allocations ✔️

Faster 🎉 in #7616

Benchmark base/diff Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark.WriteAndFlushEnrichedTraces‑net6.0 1.144 734,500.83 641,792.41

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master WriteAndFlushEnrichedTraces net6.0 735μs 653ns 2.53μs 0 0 0 41.6 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 730μs 4.14μs 28.4μs 0 0 0 41.94 KB
master WriteAndFlushEnrichedTraces net472 972μs 4.41μs 16.5μs 4.81 0 0 56.15 KB
#7616 WriteAndFlushEnrichedTraces net6.0 641μs 422ns 1.84μs 0 0 0 41.64 KB
#7616 WriteAndFlushEnrichedTraces netcoreapp3.1 791μs 4.64μs 44.3μs 0 0 0 41.81 KB
#7616 WriteAndFlushEnrichedTraces net472 956μs 3.8μs 14.7μs 4.81 0 0 56.02 KB
Benchmarks.Trace.DbCommandBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master ExecuteNonQuery net6.0 1.91μs 8.69ns 33.6ns 0 0 0 1.02 KB
master ExecuteNonQuery netcoreapp3.1 2.7μs 8.43ns 32.6ns 0 0 0 1.02 KB
master ExecuteNonQuery net472 2.86μs 2.66ns 10.3ns 0.143 0.0143 0 987 B
#7616 ExecuteNonQuery net6.0 1.84μs 4.57ns 17.7ns 0 0 0 1.02 KB
#7616 ExecuteNonQuery netcoreapp3.1 2.61μs 9.75ns 37.8ns 0 0 0 1.02 KB
#7616 ExecuteNonQuery net472 2.94μs 5.23ns 20.3ns 0.146 0.0146 0 987 B
Benchmarks.Trace.ElasticsearchBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master CallElasticsearch net6.0 1.69μs 3.01ns 11.7ns 0 0 0 1.03 KB
master CallElasticsearch netcoreapp3.1 2.2μs 8.38ns 31.4ns 0 0 0 1.03 KB
master CallElasticsearch net472 3.71μs 2.84ns 10.3ns 0.151 0 0 1.04 KB
master CallElasticsearchAsync net6.0 1.88μs 9.33ns 42.8ns 0 0 0 1.01 KB
master CallElasticsearchAsync netcoreapp3.1 2.35μs 11.8ns 50.2ns 0 0 0 1.08 KB
master CallElasticsearchAsync net472 3.83μs 12.5ns 48.5ns 0.17 0 0 1.1 KB
#7616 CallElasticsearch net6.0 1.71μs 9.01ns 43.2ns 0 0 0 1.03 KB
#7616 CallElasticsearch netcoreapp3.1 2.19μs 10.5ns 45.9ns 0 0 0 1.03 KB
#7616 CallElasticsearch net472 3.59μs 1.31ns 4.91ns 0.161 0 0 1.04 KB
#7616 CallElasticsearchAsync net6.0 1.82μs 8.67ns 33.6ns 0 0 0 1.01 KB
#7616 CallElasticsearchAsync netcoreapp3.1 2.42μs 13ns 66.1ns 0 0 0 1.08 KB
#7616 CallElasticsearchAsync net472 3.68μs 1.83ns 6.6ns 0.167 0 0 1.1 KB
Benchmarks.Trace.GraphQLBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master ExecuteAsync net6.0 1.9μs 7.01ns 27.2ns 0 0 0 952 B
master ExecuteAsync netcoreapp3.1 2.59μs 2.17ns 8.39ns 0 0 0 952 B
master ExecuteAsync net472 2.6μs 1.3ns 5.05ns 0.142 0 0 915 B
#7616 ExecuteAsync net6.0 1.83μs 8.54ns 33.1ns 0 0 0 952 B
#7616 ExecuteAsync netcoreapp3.1 2.47μs 5.96ns 23.1ns 0 0 0 952 B
#7616 ExecuteAsync net472 2.63μs 1.76ns 6.59ns 0.145 0 0 915 B
Benchmarks.Trace.HttpClientBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master SendAsync net6.0 6.92μs 5.9ns 22.9ns 0 0 0 2.36 KB
master SendAsync netcoreapp3.1 8.85μs 23.9ns 92.5ns 0 0 0 2.9 KB
master SendAsync net472 12.1μs 9.8ns 37.9ns 0.486 0 0 3.18 KB
#7616 SendAsync net6.0 6.73μs 30.7ns 119ns 0 0 0 2.36 KB
#7616 SendAsync netcoreapp3.1 8.27μs 23.1ns 89.6ns 0 0 0 2.9 KB
#7616 SendAsync net472 12μs 12.3ns 47.8ns 0.476 0 0 3.18 KB
Benchmarks.Trace.Iast.StringAspectsBenchmark - Same speed ✔️ More allocations ⚠️

More allocations ⚠️ in #7616

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑netcoreapp3.1 255.67 KB 273.82 KB 18.15 KB 7.10%
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑netcoreapp3.1 42.64 KB 44.04 KB 1.4 KB 3.28%

Fewer allocations 🎉 in #7616

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0 275.65 KB 258.63 KB -17.02 KB -6.17%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StringConcatBenchmark net6.0 50.1μs 909ns 9.09μs 0 0 0 43.78 KB
master StringConcatBenchmark netcoreapp3.1 47.1μs 237ns 1.01μs 0 0 0 42.64 KB
master StringConcatBenchmark net472 58μs 264ns 988ns 0 0 0 65.54 KB
master StringConcatAspectBenchmark net6.0 467μs 1.65μs 5.7μs 0 0 0 275.65 KB
master StringConcatAspectBenchmark netcoreapp3.1 490μs 2.26μs 8.47μs 0 0 0 255.67 KB
master StringConcatAspectBenchmark net472 409μs 2.31μs 16.5μs 0 0 0 278.53 KB
#7616 StringConcatBenchmark net6.0 46.8μs 547ns 5.33μs 0 0 0 43.99 KB
#7616 StringConcatBenchmark netcoreapp3.1 46.6μs 227ns 907ns 0 0 0 44.04 KB
#7616 StringConcatBenchmark net472 56.5μs 302ns 1.51μs 0 0 0 65.54 KB
#7616 StringConcatAspectBenchmark net6.0 457μs 2.21μs 11.5μs 0 0 0 258.63 KB
#7616 StringConcatAspectBenchmark netcoreapp3.1 532μs 2.38μs 8.56μs 0 0 0 273.82 KB
#7616 StringConcatAspectBenchmark net472 395μs 1.64μs 5.93μs 0 0 0 278.53 KB
Benchmarks.Trace.ILoggerBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 2.67μs 13.4ns 59.8ns 0 0 0 1.7 KB
master EnrichedLog netcoreapp3.1 3.76μs 13.5ns 52.3ns 0 0 0 1.7 KB
master EnrichedLog net472 4.02μs 4.66ns 18.1ns 0.243 0 0 1.64 KB
#7616 EnrichedLog net6.0 2.65μs 1.01ns 3.89ns 0 0 0 1.7 KB
#7616 EnrichedLog netcoreapp3.1 3.77μs 14.9ns 57.9ns 0 0 0 1.7 KB
#7616 EnrichedLog net472 4.04μs 3.5ns 13.6ns 0.241 0 0 1.64 KB
Benchmarks.Trace.Log4netBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 123μs 95.9ns 371ns 0 0 0 4.31 KB
master EnrichedLog netcoreapp3.1 128μs 253ns 911ns 0 0 0 4.31 KB
master EnrichedLog net472 169μs 94.3ns 353ns 0 0 0 4.52 KB
#7616 EnrichedLog net6.0 123μs 69.2ns 249ns 0 0 0 4.31 KB
#7616 EnrichedLog netcoreapp3.1 132μs 649ns 2.97μs 0 0 0 4.31 KB
#7616 EnrichedLog net472 168μs 151ns 586ns 0 0 0 4.52 KB
Benchmarks.Trace.NLogBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 5.17μs 18.2ns 70.7ns 0 0 0 2.26 KB
master EnrichedLog netcoreapp3.1 6.68μs 27.4ns 106ns 0 0 0 2.26 KB
master EnrichedLog net472 7.58μs 12.9ns 50ns 0.301 0 0 2.08 KB
#7616 EnrichedLog net6.0 5.07μs 5.83ns 22.6ns 0 0 0 2.26 KB
#7616 EnrichedLog netcoreapp3.1 6.96μs 8.99ns 34.8ns 0 0 0 2.26 KB
#7616 EnrichedLog net472 7.6μs 5.86ns 22.7ns 0.302 0 0 2.08 KB
Benchmarks.Trace.RedisBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master SendReceive net6.0 1.95μs 8.97ns 35.9ns 0 0 0 1.2 KB
master SendReceive netcoreapp3.1 2.72μs 13.4ns 53.5ns 0 0 0 1.2 KB
master SendReceive net472 3.01μs 3.5ns 13.6ns 0.18 0 0 1.2 KB
#7616 SendReceive net6.0 1.98μs 10.5ns 54.7ns 0 0 0 1.2 KB
#7616 SendReceive netcoreapp3.1 2.55μs 12.9ns 56.2ns 0 0 0 1.2 KB
#7616 SendReceive net472 3.06μs 2.74ns 10.3ns 0.183 0 0 1.2 KB
Benchmarks.Trace.SerilogBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 4.39μs 12.4ns 46.5ns 0 0 0 1.58 KB
master EnrichedLog netcoreapp3.1 5.68μs 7.46ns 28.9ns 0 0 0 1.63 KB
master EnrichedLog net472 6.69μs 6.1ns 23.6ns 0.299 0 0 2.03 KB
#7616 EnrichedLog net6.0 4.21μs 11.5ns 43.2ns 0 0 0 1.58 KB
#7616 EnrichedLog netcoreapp3.1 5.62μs 9.52ns 36.9ns 0 0 0 1.63 KB
#7616 EnrichedLog net472 6.58μs 7.17ns 26.8ns 0.294 0 0 2.03 KB
Benchmarks.Trace.SpanBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartFinishSpan net6.0 784ns 0.189ns 0.706ns 0 0 0 576 B
master StartFinishSpan netcoreapp3.1 989ns 5.1ns 23.9ns 0 0 0 576 B
master StartFinishSpan net472 931ns 0.474ns 1.84ns 0.0888 0 0 578 B
master StartFinishScope net6.0 922ns 4.14ns 15.5ns 0 0 0 696 B
master StartFinishScope netcoreapp3.1 1.23μs 4.75ns 18.4ns 0 0 0 696 B
master StartFinishScope net472 1.12μs 0.434ns 1.68ns 0.102 0 0 658 B
#7616 StartFinishSpan net6.0 784ns 0.328ns 1.23ns 0 0 0 576 B
#7616 StartFinishSpan netcoreapp3.1 982ns 5ns 25.5ns 0 0 0 576 B
#7616 StartFinishSpan net472 933ns 3.11ns 12ns 0.0901 0 0 578 B
#7616 StartFinishScope net6.0 928ns 0.721ns 2.7ns 0 0 0 696 B
#7616 StartFinishScope netcoreapp3.1 1.2μs 6.15ns 29.5ns 0 0 0 696 B
#7616 StartFinishScope net472 1.11μs 1.24ns 4.8ns 0.101 0 0 658 B
Benchmarks.Trace.TraceAnnotationsBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master RunOnMethodBegin net6.0 1.07μs 5.18ns 20.7ns 0 0 0 696 B
master RunOnMethodBegin netcoreapp3.1 1.46μs 3.91ns 15.2ns 0 0 0 696 B
master RunOnMethodBegin net472 1.48μs 1.61ns 6.23ns 0.104 0 0 658 B
#7616 RunOnMethodBegin net6.0 1.06μs 5.49ns 28ns 0 0 0 696 B
#7616 RunOnMethodBegin netcoreapp3.1 1.4μs 5.37ns 20.8ns 0 0 0 696 B
#7616 RunOnMethodBegin net472 1.49μs 1.45ns 5.63ns 0.104 0 0 658 B

@lucaspimentel lucaspimentel changed the title [config] Add DD_DISCOVERY_SERVICE_ENABLED setting [config] Add DD_AGENT_FEATURE_POLLING_ENABLED setting Oct 22, 2025
@lucaspimentel lucaspimentel force-pushed the lpimentel/disable-discovery-service branch from 2fbfdd1 to c28a6f3 Compare October 23, 2025 22:48
@lucaspimentel lucaspimentel changed the title [config] Add DD_AGENT_FEATURE_POLLING_ENABLED setting Add DD_AGENT_FEATURE_POLLING_ENABLED setting Oct 23, 2025
Copy link
Collaborator

@NachoEchevarria NachoEchevarria left a comment

Choose a reason for hiding this comment

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

LGTM!

@lucaspimentel lucaspimentel requested a review from a team October 27, 2025 23:05
Copy link
Member

@andrewlock andrewlock left a comment

Choose a reason for hiding this comment

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

LGTM

Only outstanding questions are whether this setting should apply to ci vis too or not 🤷‍♂️ If yes, then we should also update TestOptimization and also the datadog runner, which uses the discovery service to "pre-discover" stuff and pass it through as env vars


protected override IDiscoveryService GetDiscoveryService(TracerSettings settings)
internal override IDiscoveryService GetDiscoveryService(TracerSettings settings)
=> _testOptimizationTracerManagement.DiscoveryService;
Copy link
Member

Choose a reason for hiding this comment

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

Should TestOptimization also respect this setting? If so we prob need to update it there too

Copy link
Member Author

Choose a reason for hiding this comment

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

TestOptimizationTracerManagerFactory always uses NullDiscoveryService.Instance.

public TestOptimizationTracerManagement(
TestOptimizationSettings settings,
EventPlatformProxySupport eventPlatformProxySupport = EventPlatformProxySupport.None,
bool useLockedTracerManager = true)
{
_settings = settings;
DiscoveryService = NullDiscoveryService.Instance;

@lucaspimentel lucaspimentel force-pushed the lpimentel/disable-discovery-service branch 2 times, most recently from f6edf4e to 42af675 Compare November 7, 2025 01:57
@lucaspimentel lucaspimentel enabled auto-merge (squash) November 7, 2025 20:48
@lucaspimentel lucaspimentel force-pushed the lpimentel/disable-discovery-service branch from 12c9169 to fa1c264 Compare November 7, 2025 22:26
@lucaspimentel lucaspimentel merged commit 76c97b1 into master Nov 7, 2025
151 checks passed
@lucaspimentel lucaspimentel deleted the lpimentel/disable-discovery-service branch November 7, 2025 23:34
@github-actions github-actions bot added this to the vNext-v3 milestone Nov 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants