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

[v3] Remove unnecessary System.Net.Http dependency from v3 #5418

Merged
merged 1 commit into from
Apr 25, 2024

Conversation

andrewlock
Copy link
Member

Summary of changes

Removes the NuGet reference to System.Net.Http

Reason for change

This reference isn't necessary, as System.Net.Http.HttpHeaders is available in all versions of .NET Standard and .NET Core.

Implementation details

Just removed the reference. This makes no change to the referenced assemblies, and it has no impact on application that reference Datadog.Trace.OpenTracing because the library is only ever copied if it's required.

Test coverage

I did a manual test, adding Datadog.Trace.OpenTracing to a console app, and confirmed the output doesn't currently include any extra dlls etc

Other details

Fixes #5377

@andrewlock andrewlock requested a review from a team as a code owner April 9, 2024 13:21
@datadog-ddstaging
Copy link

datadog-ddstaging bot commented Apr 9, 2024

Datadog Report

Branch report: andrew/v3/remove-open-tracing-dependency
Commit report: 7bc8665
Test service: dd-trace-dotnet

✅ 0 Failed, 342302 Passed, 2274 Skipped, 49m 13.76s Wall Time
❄️ 2 New Flaky

New Flaky Tests (2)

  • TelemetryControllerShouldSendGitMetadataWithTelemetry - Datadog.Trace.Tests.Telemetry.TelemetryControllerTests - Last Failure

    Expand for error
     Transport did not receive required data before the timeout 60000ms
    
  • TelemetryControllerShouldSendGitMetadataWithTelemetry - Datadog.Trace.Tests.Telemetry.TelemetryControllerTests - Last Failure

    Expand for error
     Transport did not receive required data before the timeout 60000ms
    

@andrewlock
Copy link
Member Author

andrewlock commented Apr 9, 2024

Execution-Time Benchmarks Report ⏱️

Execution-time results for samples comparing the following branches/commits:

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 shown 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).

gantt
    title Execution time (ms) FakeDbCommand (.NET Framework 4.6.2) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5418) - mean (75ms)  : 68, 81
     .   : milestone, 75,
    master - mean (73ms)  : 64, 82
     .   : milestone, 73,

    section CallTarget+Inlining+NGEN
    This PR (5418) - mean (1,027ms)  : 1000, 1054
     .   : milestone, 1027,
    master - mean (1,015ms)  : 995, 1035
     .   : milestone, 1015,

Loading
gantt
    title Execution time (ms) FakeDbCommand (.NET Core 3.1) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5418) - mean (110ms)  : 106, 114
     .   : milestone, 110,
    master - mean (110ms)  : 105, 114
     .   : milestone, 110,

    section CallTarget+Inlining+NGEN
    This PR (5418) - mean (749ms)  : 722, 777
     .   : milestone, 749,
    master - mean (730ms)  : 709, 750
     .   : milestone, 730,

Loading
gantt
    title Execution time (ms) FakeDbCommand (.NET 6) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5418) - mean (94ms)  : 91, 98
     .   : milestone, 94,
    master - mean (95ms)  : 90, 99
     .   : milestone, 95,

    section CallTarget+Inlining+NGEN
    This PR (5418) - mean (701ms)  : 681, 722
     .   : milestone, 701,
    master - mean (684ms)  : 666, 703
     .   : milestone, 684,

Loading
gantt
    title Execution time (ms) HttpMessageHandler (.NET Framework 4.6.2) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5418) - mean (190ms)  : 187, 194
     .   : milestone, 190,
    master - mean (191ms)  : 187, 195
     .   : milestone, 191,

    section CallTarget+Inlining+NGEN
    This PR (5418) - mean (1,109ms)  : 1082, 1136
     .   : milestone, 1109,
    master - mean (1,099ms)  : 1076, 1121
     .   : milestone, 1099,

Loading
gantt
    title Execution time (ms) HttpMessageHandler (.NET Core 3.1) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5418) - mean (276ms)  : 271, 281
     .   : milestone, 276,
    master - mean (276ms)  : 271, 280
     .   : milestone, 276,

    section CallTarget+Inlining+NGEN
    This PR (5418) - mean (893ms)  : 865, 920
     .   : milestone, 893,
    master - mean (886ms)  : 863, 910
     .   : milestone, 886,

Loading
gantt
    title Execution time (ms) HttpMessageHandler (.NET 6) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5418) - mean (264ms)  : 260, 268
     .   : milestone, 264,
    master - mean (266ms)  : 261, 271
     .   : milestone, 266,

    section CallTarget+Inlining+NGEN
    This PR (5418) - mean (882ms)  : 851, 913
     .   : milestone, 882,
    master - mean (869ms)  : 839, 898
     .   : milestone, 869,

Loading

@andrewlock
Copy link
Member Author

andrewlock commented Apr 9, 2024

Benchmarks Report for tracer 🐌

Benchmarks for #5418 compared to master:

  • 3 benchmarks are slower, with geometric mean 1.146
  • All benchmarks have the same 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 ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartStopWithChild net6.0 8.71μs 48.7ns 334ns 0.022 0.00881 0 7.56 KB
master StartStopWithChild netcoreapp3.1 10.7μs 49.4ns 191ns 0.0209 0.0105 0 7.66 KB
master StartStopWithChild net472 17.1μs 45.8ns 171ns 1.34 0.34 0.102 8.08 KB
#5418 StartStopWithChild net6.0 8.55μs 47.1ns 270ns 0.0207 0.00826 0 7.55 KB
#5418 StartStopWithChild netcoreapp3.1 11.2μs 61ns 356ns 0.0282 0.0113 0 7.65 KB
#5418 StartStopWithChild net472 17.1μs 38.6ns 149ns 1.35 0.373 0.113 8.1 KB
Benchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master WriteAndFlushEnrichedTraces net6.0 474μs 235ns 912ns 0 0 0 2.7 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 644μs 321ns 1.24μs 0 0 0 2.7 KB
master WriteAndFlushEnrichedTraces net472 822μs 425ns 1.65μs 0.411 0 0 3.3 KB
#5418 WriteAndFlushEnrichedTraces net6.0 462μs 314ns 1.18μs 0 0 0 2.7 KB
#5418 WriteAndFlushEnrichedTraces netcoreapp3.1 637μs 284ns 1.02μs 0 0 0 2.7 KB
#5418 WriteAndFlushEnrichedTraces net472 812μs 608ns 2.36μs 0.403 0 0 3.3 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 170μs 224ns 867ns 0.17 0 0 18.49 KB
master SendRequest netcoreapp3.1 193μs 257ns 995ns 0.191 0 0 20.65 KB
master SendRequest net472 0.000467ns 0.000194ns 0.000727ns 0 0 0 0 b
#5418 SendRequest net6.0 172μs 243ns 939ns 0.258 0 0 18.49 KB
#5418 SendRequest netcoreapp3.1 189μs 273ns 1.06μs 0.188 0 0 20.65 KB
#5418 SendRequest net472 0.000426ns 0.000231ns 0.000834ns 0 0 0 0 b
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master WriteAndFlushEnrichedTraces net6.0 552μs 1.4μs 5.41μs 0.561 0 0 41.58 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 653μs 1.05μs 3.8μs 0.332 0 0 41.65 KB
master WriteAndFlushEnrichedTraces net472 857μs 3.11μs 12.1μs 8.08 2.55 0.425 53.22 KB
#5418 WriteAndFlushEnrichedTraces net6.0 555μs 639ns 2.47μs 0.553 0 0 41.57 KB
#5418 WriteAndFlushEnrichedTraces netcoreapp3.1 655μs 1.31μs 5.09μs 0.326 0 0 41.72 KB
#5418 WriteAndFlushEnrichedTraces net472 871μs 4.31μs 24.4μs 8.19 2.59 0.431 53.26 KB
Benchmarks.Trace.DbCommandBenchmark - Slower ⚠️ Same allocations ✔️

Slower ⚠️ in #5418

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.DbCommandBenchmark.ExecuteNonQuery‑net6.0 1.123 1,163.55 1,306.30

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master ExecuteNonQuery net6.0 1.16μs 0.373ns 1.4ns 0.0111 0 0 808 B
master ExecuteNonQuery netcoreapp3.1 1.46μs 0.765ns 2.96ns 0.011 0 0 808 B
master ExecuteNonQuery net472 1.83μs 1.19ns 4.61ns 0.122 0 0 770 B
#5418 ExecuteNonQuery net6.0 1.31μs 0.446ns 1.73ns 0.0111 0 0 808 B
#5418 ExecuteNonQuery netcoreapp3.1 1.54μs 1.05ns 4.07ns 0.0107 0 0 808 B
#5418 ExecuteNonQuery net472 1.84μs 0.883ns 3.3ns 0.122 0 0 770 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.21μs 0.348ns 1.3ns 0.0146 0 0 1.03 KB
master CallElasticsearch netcoreapp3.1 1.66μs 0.499ns 1.8ns 0.014 0 0 1.03 KB
master CallElasticsearch net472 2.55μs 1.86ns 7.22ns 0.166 0 0 1.04 KB
master CallElasticsearchAsync net6.0 1.36μs 1.56ns 6.05ns 0.0144 0 0 1.01 KB
master CallElasticsearchAsync netcoreapp3.1 1.7μs 1.13ns 4.22ns 0.0145 0 0 1.08 KB
master CallElasticsearchAsync net472 2.65μs 1.82ns 7.04ns 0.175 0 0 1.1 KB
#5418 CallElasticsearch net6.0 1.28μs 0.806ns 3.02ns 0.0142 0 0 1.03 KB
#5418 CallElasticsearch netcoreapp3.1 1.6μs 1.1ns 3.81ns 0.0136 0 0 1.03 KB
#5418 CallElasticsearch net472 2.53μs 1.48ns 5.53ns 0.165 0 0 1.04 KB
#5418 CallElasticsearchAsync net6.0 1.39μs 0.612ns 2.37ns 0.0139 0 0 1.01 KB
#5418 CallElasticsearchAsync netcoreapp3.1 1.65μs 2.28ns 8.81ns 0.0141 0 0 1.08 KB
#5418 CallElasticsearchAsync net472 2.61μs 1.02ns 3.68ns 0.174 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.36μs 0.495ns 1.78ns 0.0136 0 0 952 B
master ExecuteAsync netcoreapp3.1 1.61μs 0.575ns 2.23ns 0.0131 0 0 952 B
master ExecuteAsync net472 1.82μs 0.761ns 2.85ns 0.145 0 0 915 B
#5418 ExecuteAsync net6.0 1.38μs 0.48ns 1.86ns 0.0132 0 0 952 B
#5418 ExecuteAsync netcoreapp3.1 1.69μs 0.533ns 2.06ns 0.0127 0 0 952 B
#5418 ExecuteAsync net472 1.75μs 0.823ns 3.19ns 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 4.22μs 2.89ns 10.8ns 0.0315 0 0 2.27 KB
master SendAsync netcoreapp3.1 5.03μs 2.07ns 7.73ns 0.0381 0 0 2.81 KB
master SendAsync net472 7.89μs 2.12ns 7.65ns 0.503 0 0 3.18 KB
#5418 SendAsync net6.0 4.13μs 1.11ns 4.02ns 0.0312 0 0 2.27 KB
#5418 SendAsync netcoreapp3.1 5.29μs 1.83ns 7.08ns 0.0369 0 0 2.81 KB
#5418 SendAsync net472 7.84μs 5.3ns 20.5ns 0.502 0 0 3.18 KB
Benchmarks.Trace.ILoggerBenchmark - Slower ⚠️ Same allocations ✔️

Slower ⚠️ in #5418

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.ILoggerBenchmark.EnrichedLog‑net6.0 1.125 1,496.21 1,682.92

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 1.5μs 0.778ns 3.01ns 0.0238 0 0 1.7 KB
master EnrichedLog netcoreapp3.1 2.35μs 1.59ns 6.18ns 0.0234 0 0 1.7 KB
master EnrichedLog net472 2.74μs 3.95ns 15.3ns 0.257 0 0 1.62 KB
#5418 EnrichedLog net6.0 1.68μs 0.933ns 3.49ns 0.0236 0 0 1.7 KB
#5418 EnrichedLog netcoreapp3.1 2.19μs 1.98ns 7.43ns 0.0229 0 0 1.7 KB
#5418 EnrichedLog net472 2.62μs 2.65ns 9.55ns 0.257 0 0 1.62 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 113μs 104ns 375ns 0 0 0 4.28 KB
master EnrichedLog netcoreapp3.1 122μs 295ns 1.14μs 0 0 0 4.28 KB
master EnrichedLog net472 152μs 139ns 501ns 0.675 0.225 0 4.46 KB
#5418 EnrichedLog net6.0 113μs 229ns 856ns 0.0569 0 0 4.28 KB
#5418 EnrichedLog netcoreapp3.1 121μs 217ns 810ns 0 0 0 4.28 KB
#5418 EnrichedLog net472 150μs 183ns 707ns 0.675 0.225 0 4.46 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 3.08μs 2.72ns 10.5ns 0.0309 0 0 2.25 KB
master EnrichedLog netcoreapp3.1 4.33μs 2.12ns 8.19ns 0.0303 0 0 2.25 KB
master EnrichedLog net472 4.82μs 1.78ns 6.89ns 0.327 0 0 2.07 KB
#5418 EnrichedLog net6.0 2.96μs 0.83ns 3.21ns 0.031 0 0 2.25 KB
#5418 EnrichedLog netcoreapp3.1 4.17μs 1.67ns 6.26ns 0.0308 0 0 2.25 KB
#5418 EnrichedLog net472 4.86μs 1.26ns 4.87ns 0.328 0 0 2.07 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.42μs 0.838ns 3.14ns 0.0168 0 0 1.2 KB
master SendReceive netcoreapp3.1 1.87μs 0.952ns 3.69ns 0.0159 0 0 1.2 KB
master SendReceive net472 2.15μs 1.82ns 7.06ns 0.19 0 0 1.2 KB
#5418 SendReceive net6.0 1.48μs 1.8ns 6.73ns 0.017 0 0 1.2 KB
#5418 SendReceive netcoreapp3.1 1.84μs 1.64ns 6.34ns 0.0157 0 0 1.2 KB
#5418 SendReceive net472 2.38μs 3.1ns 12ns 0.191 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 2.66μs 0.784ns 2.93ns 0.0227 0 0 1.6 KB
master EnrichedLog netcoreapp3.1 3.88μs 0.693ns 2.5ns 0.0214 0 0 1.65 KB
master EnrichedLog net472 4.56μs 1.39ns 5.21ns 0.322 0 0 2.04 KB
#5418 EnrichedLog net6.0 2.76μs 0.827ns 3.09ns 0.0219 0 0 1.6 KB
#5418 EnrichedLog netcoreapp3.1 3.94μs 1.59ns 5.95ns 0.0216 0 0 1.65 KB
#5418 EnrichedLog net472 4.44μs 1.51ns 5.43ns 0.323 0 0 2.04 KB
Benchmarks.Trace.SpanBenchmark - Slower ⚠️ Same allocations ✔️

Slower ⚠️ in #5418

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.SpanBenchmark.StartFinishScope‑netcoreapp3.1 1.190 817.32 972.98

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartFinishSpan net6.0 528ns 0.14ns 0.541ns 0.00815 0 0 576 B
master StartFinishSpan netcoreapp3.1 738ns 0.284ns 1.1ns 0.00785 0 0 576 B
master StartFinishSpan net472 792ns 0.406ns 1.57ns 0.0918 0 0 578 B
master StartFinishScope net6.0 604ns 0.146ns 0.546ns 0.00977 0 0 696 B
master StartFinishScope netcoreapp3.1 817ns 1.1ns 4.25ns 0.00936 0 0 696 B
master StartFinishScope net472 994ns 0.46ns 1.78ns 0.104 0 0 658 B
#5418 StartFinishSpan net6.0 476ns 0.126ns 0.471ns 0.00797 0 0 576 B
#5418 StartFinishSpan netcoreapp3.1 697ns 0.263ns 0.948ns 0.00791 0 0 576 B
#5418 StartFinishSpan net472 781ns 0.318ns 1.23ns 0.0916 0 0 578 B
#5418 StartFinishScope net6.0 671ns 0.242ns 0.937ns 0.00976 0 0 696 B
#5418 StartFinishScope netcoreapp3.1 972ns 0.501ns 1.87ns 0.00922 0 0 696 B
#5418 StartFinishScope net472 1.02μs 0.537ns 2.01ns 0.105 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 674ns 0.684ns 2.37ns 0.00979 0 0 696 B
master RunOnMethodBegin netcoreapp3.1 934ns 0.606ns 2.35ns 0.00907 0 0 696 B
master RunOnMethodBegin net472 1.19μs 0.461ns 1.79ns 0.104 0 0 658 B
#5418 RunOnMethodBegin net6.0 661ns 0.301ns 1.16ns 0.0099 0 0 696 B
#5418 RunOnMethodBegin netcoreapp3.1 901ns 0.325ns 1.22ns 0.0092 0 0 696 B
#5418 RunOnMethodBegin net472 1.16μs 0.428ns 1.66ns 0.104 0 0 658 B

@andrewlock
Copy link
Member Author

andrewlock commented Apr 9, 2024

Benchmarks Report for appsec 🐌

Benchmarks for #5418 compared to master:

  • 1 benchmarks are faster, with geometric mean 1.121
  • 1 benchmarks are slower, with geometric mean 1.853
  • 1 benchmarks have fewer allocations
  • 3 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.Asm.AppSecBodyBenchmark - Faster 🎉 Same allocations ✔️

Faster 🎉 in #5418

Benchmark base/diff Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.Asm.AppSecBodyBenchmark.ObjectExtractorSimpleBody‑netcoreapp3.1 1.121 233.63 208.42

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master AllCycleSimpleBody net6.0 72.4μs 144ns 559ns 0.0717 0 0 6 KB
master AllCycleSimpleBody netcoreapp3.1 63.7μs 167ns 646ns 0.064 0 0 6.94 KB
master AllCycleSimpleBody net472 48.1μs 79.5ns 298ns 1.3 0 0 8.33 KB
master AllCycleMoreComplexBody net6.0 76.8μs 61.7ns 222ns 0.116 0 0 9.5 KB
master AllCycleMoreComplexBody netcoreapp3.1 70.5μs 77.8ns 291ns 0.14 0 0 10.36 KB
master AllCycleMoreComplexBody net472 56μs 98.7ns 356ns 1.87 0.0279 0 11.84 KB
master ObjectExtractorSimpleBody net6.0 152ns 0.124ns 0.479ns 0.00394 0 0 280 B
master ObjectExtractorSimpleBody netcoreapp3.1 234ns 0.321ns 1.24ns 0.00364 0 0 272 B
master ObjectExtractorSimpleBody net472 168ns 0.149ns 0.557ns 0.0446 0 0 281 B
master ObjectExtractorMoreComplexBody net6.0 2.99μs 10.6ns 39.6ns 0.0528 0 0 3.78 KB
master ObjectExtractorMoreComplexBody netcoreapp3.1 3.99μs 1.67ns 6.46ns 0.0498 0 0 3.69 KB
master ObjectExtractorMoreComplexBody net472 3.84μs 2.4ns 9.31ns 0.602 0.00579 0 3.8 KB
#5418 AllCycleSimpleBody net6.0 73.4μs 77.9ns 292ns 0.0726 0 0 6 KB
#5418 AllCycleSimpleBody netcoreapp3.1 62.7μs 72.4ns 271ns 0.0634 0 0 6.94 KB
#5418 AllCycleSimpleBody net472 48.5μs 107ns 416ns 1.32 0 0 8.33 KB
#5418 AllCycleMoreComplexBody net6.0 77.9μs 97.6ns 378ns 0.117 0 0 9.5 KB
#5418 AllCycleMoreComplexBody netcoreapp3.1 70.3μs 74.3ns 278ns 0.141 0 0 10.36 KB
#5418 AllCycleMoreComplexBody net472 55.2μs 59.6ns 231ns 1.87 0.0275 0 11.84 KB
#5418 ObjectExtractorSimpleBody net6.0 147ns 0.13ns 0.488ns 0.00394 0 0 280 B
#5418 ObjectExtractorSimpleBody netcoreapp3.1 208ns 0.0749ns 0.29ns 0.00376 0 0 272 B
#5418 ObjectExtractorSimpleBody net472 165ns 0.131ns 0.506ns 0.0446 0 0 281 B
#5418 ObjectExtractorMoreComplexBody net6.0 2.94μs 1.08ns 4.03ns 0.0528 0 0 3.78 KB
#5418 ObjectExtractorMoreComplexBody netcoreapp3.1 3.86μs 7.4ns 26.7ns 0.05 0 0 3.69 KB
#5418 ObjectExtractorMoreComplexBody net472 3.79μs 2.2ns 7.93ns 0.602 0.00569 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 40.8μs 16.5ns 63.8ns 0.451 0 0 32.4 KB
master EncodeArgs netcoreapp3.1 55μs 44.2ns 171ns 0.438 0 0 32.4 KB
master EncodeArgs net472 70.3μs 62.5ns 242ns 5.13 0.0698 0 32.5 KB
master EncodeLegacyArgs net6.0 74.9μs 408ns 2.23μs 0.0358 0 0 2.14 KB
master EncodeLegacyArgs netcoreapp3.1 106μs 267ns 1.03μs 0 0 0 2.14 KB
master EncodeLegacyArgs net472 153μs 143ns 554ns 0.309 0 0 2.15 KB
#5418 EncodeArgs net6.0 40μs 21.5ns 83.2ns 0.459 0 0 32.4 KB
#5418 EncodeArgs netcoreapp3.1 55.5μs 31.4ns 122ns 0.442 0 0 32.4 KB
#5418 EncodeArgs net472 68.1μs 64.7ns 251ns 5.13 0.068 0 32.5 KB
#5418 EncodeLegacyArgs net6.0 76.5μs 353ns 1.65μs 0.0387 0 0 2.14 KB
#5418 EncodeLegacyArgs netcoreapp3.1 106μs 155ns 598ns 0 0 0 2.14 KB
#5418 EncodeLegacyArgs net472 151μs 89.7ns 348ns 0.303 0 0 2.15 KB
Benchmarks.Trace.Asm.AppSecWafBenchmark - Same speed ✔️ Same allocations ✔️

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master RunWafRealisticBenchmark net6.0 188μs 161ns 622ns 0 0 0 2.32 KB
master RunWafRealisticBenchmark netcoreapp3.1 199μs 267ns 1.03μs 0 0 0 2.27 KB
master RunWafRealisticBenchmark net472 219μs 90.3ns 350ns 0.327 0 0 2.34 KB
master RunWafRealisticBenchmarkWithAttack net6.0 123μs 50.5ns 189ns 0 0 0 1.43 KB
master RunWafRealisticBenchmarkWithAttack netcoreapp3.1 131μs 168ns 652ns 0 0 0 1.42 KB
master RunWafRealisticBenchmarkWithAttack net472 142μs 49.8ns 193ns 0.214 0 0 1.44 KB
#5418 RunWafRealisticBenchmark net6.0 185μs 82.4ns 319ns 0 0 0 2.32 KB
#5418 RunWafRealisticBenchmark netcoreapp3.1 200μs 347ns 1.35μs 0 0 0 2.27 KB
#5418 RunWafRealisticBenchmark net472 217μs 49.9ns 187ns 0.325 0 0 2.34 KB
#5418 RunWafRealisticBenchmarkWithAttack net6.0 123μs 75.1ns 291ns 0 0 0 1.43 KB
#5418 RunWafRealisticBenchmarkWithAttack netcoreapp3.1 132μs 99.7ns 373ns 0 0 0 1.42 KB
#5418 RunWafRealisticBenchmarkWithAttack net472 143μs 41.4ns 160ns 0.214 0 0 1.45 KB
Benchmarks.Trace.Iast.StringAspectsBenchmark - Slower ⚠️ More allocations ⚠️

Slower ⚠️ in #5418

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑netcoreapp3.1 1.853 317,800.00 589,000.00

More allocations ⚠️ in #5418

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑netcoreapp3.1 202.75 KB 266.14 KB 63.39 KB 31.27%
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑net472 60.54 KB 61.77 KB 1.22 KB 2.02%
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0 202.83 KB 205.94 KB 3.1 KB 1.53%

Fewer allocations 🎉 in #5418

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net472 233.92 KB 221.18 KB -12.74 KB -5.44%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StringConcatBenchmark net6.0 58.7μs 747ns 7.44μs 0 0 0 43.44 KB
master StringConcatBenchmark netcoreapp3.1 60μs 739ns 7.32μs 0 0 0 42.64 KB
master StringConcatBenchmark net472 38.1μs 127ns 458ns 0 0 0 60.54 KB
master StringConcatAspectBenchmark net6.0 287μs 1.4μs 7.81μs 0 0 0 202.83 KB
master StringConcatAspectBenchmark netcoreapp3.1 321μs 1.72μs 9.45μs 0 0 0 202.75 KB
master StringConcatAspectBenchmark net472 239μs 1.17μs 5.25μs 0 0 0 233.92 KB
#5418 StringConcatBenchmark net6.0 60.7μs 734ns 7.3μs 0 0 0 43.44 KB
#5418 StringConcatBenchmark netcoreapp3.1 53.7μs 261ns 1.08μs 0 0 0 42.64 KB
#5418 StringConcatBenchmark net472 37.5μs 65.5ns 236ns 0 0 0 61.77 KB
#5418 StringConcatAspectBenchmark net6.0 296μs 1.24μs 4.65μs 0 0 0 205.94 KB
#5418 StringConcatAspectBenchmark netcoreapp3.1 589μs 2.97μs 12.9μs 0 0 0 266.14 KB
#5418 StringConcatAspectBenchmark net472 230μs 1.19μs 5.71μs 0 0 0 221.18 KB

@andrewlock
Copy link
Member Author

andrewlock commented Apr 9, 2024

Throughput/Crank Report ⚡

Throughput results for AspNetCoreSimpleController comparing the following branches/commits:

Cases where throughput results for the PR are worse than latest master (5% drop or greater), results are shown in red.

Note that these results are based on a single point-in-time result for each branch. For full results, see one of the many, many dashboards!

gantt
    title Throughput Linux x64 (Total requests) 
    dateFormat  X
    axisFormat %s
    section Baseline
    This PR (5418) (11.942M)   : 0, 11942377
    master (11.797M)   : 0, 11796602
    benchmarks/2.9.0 (11.999M)   : 0, 11998866

    section Automatic
    This PR (5418) (8.172M)   : 0, 8172489
    master (8.121M)   : 0, 8121213
    benchmarks/2.9.0 (8.552M)   : 0, 8552042

    section Trace stats
    master (8.340M)   : 0, 8339858

    section Manual
    master (10.476M)   : 0, 10475581

    section Manual + Automatic
    This PR (5418) (7.592M)   : 0, 7592303
    master (7.664M)   : 0, 7663674

Loading
gantt
    title Throughput Linux arm64 (Total requests) 
    dateFormat  X
    axisFormat %s
    section Baseline
    This PR (5418) (9.638M)   : 0, 9638294
    master (9.722M)   : 0, 9721508
    benchmarks/2.9.0 (9.626M)   : 0, 9625513

    section Automatic
    This PR (5418) (6.575M)   : 0, 6574823
    master (6.543M)   : 0, 6543249

    section Trace stats
    master (6.920M)   : 0, 6920217

    section Manual
    master (8.263M)   : 0, 8263411

    section Manual + Automatic
    This PR (5418) (5.893M)   : 0, 5893452
    master (6.057M)   : 0, 6056903

Loading
gantt
    title Throughput Windows x64 (Total requests) 
    dateFormat  X
    axisFormat %s
    section Baseline
    This PR (5418) (9.758M)   : 0, 9758234
    master (9.866M)   : 0, 9866110
    benchmarks/2.9.0 (10.045M)   : 0, 10044599

    section Automatic
    This PR (5418) (6.998M)   : 0, 6998237
    master (7.133M)   : 0, 7133211
    benchmarks/2.9.0 (7.415M)   : 0, 7414837

    section Trace stats
    master (7.474M)   : 0, 7473704

    section Manual
    master (8.784M)   : 0, 8784165

    section Manual + Automatic
    This PR (5418) (6.662M)   : 0, 6661715
    master (6.842M)   : 0, 6841974

Loading

@andrewlock andrewlock force-pushed the andrew/v3/remove-open-tracing-dependency branch from 3ff28ac to 7bc8665 Compare April 24, 2024 10:45
@andrewlock andrewlock merged commit 2423238 into v3-main Apr 25, 2024
62 of 65 checks passed
@andrewlock andrewlock deleted the andrew/v3/remove-open-tracing-dependency branch April 25, 2024 08:46
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.

None yet

3 participants