-
Notifications
You must be signed in to change notification settings - Fork 140
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
[ASM] Avoid HttpRequestValidationException when reading body or namevalueCollection values #6185
base: master
Are you sure you want to change the base?
Conversation
4336d4b
to
52d9ad6
Compare
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:
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 (6185) - mean (71ms) : 68, 73
. : milestone, 71,
master - mean (70ms) : 68, 73
. : milestone, 70,
section CallTarget+Inlining+NGEN
This PR (6185) - mean (1,121ms) : 1103, 1138
. : milestone, 1121,
master - mean (1,117ms) : 1095, 1139
. : milestone, 1117,
gantt
title Execution time (ms) FakeDbCommand (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6185) - mean (110ms) : 107, 113
. : milestone, 110,
master - mean (111ms) : 107, 114
. : milestone, 111,
section CallTarget+Inlining+NGEN
This PR (6185) - mean (777ms) : 757, 797
. : milestone, 777,
master - mean (777ms) : 762, 791
. : milestone, 777,
gantt
title Execution time (ms) FakeDbCommand (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6185) - mean (94ms) : 91, 96
. : milestone, 94,
master - mean (94ms) : 90, 97
. : milestone, 94,
section CallTarget+Inlining+NGEN
This PR (6185) - mean (736ms) : 720, 751
. : milestone, 736,
master - mean (734ms) : 717, 751
. : milestone, 734,
gantt
title Execution time (ms) HttpMessageHandler (.NET Framework 4.6.2)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6185) - mean (191ms) : 187, 194
. : milestone, 191,
master - mean (191ms) : 187, 194
. : milestone, 191,
section CallTarget+Inlining+NGEN
This PR (6185) - mean (1,202ms) : 1181, 1224
. : milestone, 1202,
master - mean (1,204ms) : 1177, 1232
. : milestone, 1204,
gantt
title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6185) - mean (276ms) : 272, 280
. : milestone, 276,
master - mean (275ms) : 270, 281
. : milestone, 275,
section CallTarget+Inlining+NGEN
This PR (6185) - mean (945ms) : 924, 965
. : milestone, 945,
master - mean (948ms) : 927, 969
. : milestone, 948,
gantt
title Execution time (ms) HttpMessageHandler (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6185) - mean (265ms) : 261, 269
. : milestone, 265,
master - mean (265ms) : 260, 269
. : milestone, 265,
section CallTarget+Inlining+NGEN
This PR (6185) - mean (926ms) : 907, 945
. : milestone, 926,
master - mean (929ms) : 912, 946
. : milestone, 929,
|
Datadog ReportBranch report: ❌ 4 Failed (0 Known Flaky), 367184 Passed, 2072 Skipped, 15h 33m 52.66s Total Time ❌ Failed Tests (4)
|
Benchmarks Report for appsec 🐌Benchmarks for #6185 compared to master:
The following thresholds were used for comparing the benchmark speeds:
Allocation changes below 0.5% are ignored. Benchmark detailsBenchmarks.Trace.Asm.AppSecBodyBenchmark - Faster 🎉 Same allocations ✔️
|
Benchmark | base/diff | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.Asm.AppSecBodyBenchmark.ObjectExtractorSimpleBody‑net472 | 1.345 | 228.84 | 170.11 | |
Benchmarks.Trace.Asm.AppSecBodyBenchmark.ObjectExtractorSimpleBody‑netcoreapp3.1 | 1.139 | 231.78 | 203.52 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | AllCycleSimpleBody |
net6.0 | 73.4μs | 69.3ns | 259ns | 0.0732 | 0 | 0 | 6 KB |
master | AllCycleSimpleBody |
netcoreapp3.1 | 61.9μs | 70.3ns | 263ns | 0.0924 | 0 | 0 | 6.95 KB |
master | AllCycleSimpleBody |
net472 | 48.5μs | 38.2ns | 148ns | 1.31 | 0 | 0 | 8.34 KB |
master | AllCycleMoreComplexBody |
net6.0 | 79.6μs | 56ns | 217ns | 0.117 | 0 | 0 | 9.51 KB |
master | AllCycleMoreComplexBody |
netcoreapp3.1 | 69μs | 39.9ns | 155ns | 0.138 | 0 | 0 | 10.37 KB |
master | AllCycleMoreComplexBody |
net472 | 54.9μs | 119ns | 460ns | 1.86 | 0.0278 | 0 | 11.85 KB |
master | ObjectExtractorSimpleBody |
net6.0 | 138ns | 0.196ns | 0.759ns | 0.00394 | 0 | 0 | 280 B |
master | ObjectExtractorSimpleBody |
netcoreapp3.1 | 232ns | 0.223ns | 0.864ns | 0.00371 | 0 | 0 | 272 B |
master | ObjectExtractorSimpleBody |
net472 | 229ns | 0.116ns | 0.449ns | 0.0446 | 0 | 0 | 281 B |
master | ObjectExtractorMoreComplexBody |
net6.0 | 3.05μs | 2.49ns | 9.65ns | 0.0525 | 0 | 0 | 3.78 KB |
master | ObjectExtractorMoreComplexBody |
netcoreapp3.1 | 3.89μs | 2.18ns | 8.44ns | 0.0513 | 0 | 0 | 3.69 KB |
master | ObjectExtractorMoreComplexBody |
net472 | 3.73μs | 2.62ns | 9.8ns | 0.602 | 0.00557 | 0 | 3.8 KB |
#6185 | AllCycleSimpleBody |
net6.0 | 71.8μs | 122ns | 471ns | 0.0716 | 0 | 0 | 6 KB |
#6185 | AllCycleSimpleBody |
netcoreapp3.1 | 63.9μs | 45.7ns | 177ns | 0.0947 | 0 | 0 | 6.95 KB |
#6185 | AllCycleSimpleBody |
net472 | 48.7μs | 50.1ns | 194ns | 1.31 | 0 | 0 | 8.33 KB |
#6185 | AllCycleMoreComplexBody |
net6.0 | 78.5μs | 71.4ns | 276ns | 0.118 | 0 | 0 | 9.51 KB |
#6185 | AllCycleMoreComplexBody |
netcoreapp3.1 | 69.6μs | 84.3ns | 316ns | 0.138 | 0 | 0 | 10.37 KB |
#6185 | AllCycleMoreComplexBody |
net472 | 55.9μs | 88.3ns | 342ns | 1.87 | 0.0279 | 0 | 11.85 KB |
#6185 | ObjectExtractorSimpleBody |
net6.0 | 145ns | 0.272ns | 1.02ns | 0.00396 | 0 | 0 | 280 B |
#6185 | ObjectExtractorSimpleBody |
netcoreapp3.1 | 204ns | 0.346ns | 1.29ns | 0.00358 | 0 | 0 | 272 B |
#6185 | ObjectExtractorSimpleBody |
net472 | 170ns | 0.126ns | 0.472ns | 0.0446 | 0 | 0 | 281 B |
#6185 | ObjectExtractorMoreComplexBody |
net6.0 | 3.05μs | 3.03ns | 11.7ns | 0.0531 | 0 | 0 | 3.78 KB |
#6185 | ObjectExtractorMoreComplexBody |
netcoreapp3.1 | 4.03μs | 1.79ns | 6.71ns | 0.0503 | 0 | 0 | 3.69 KB |
#6185 | ObjectExtractorMoreComplexBody |
net472 | 3.77μs | 2.35ns | 8.78ns | 0.603 | 0.00567 | 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 | 38.5μs | 19.7ns | 73.9ns | 0.444 | 0 | 0 | 32.4 KB |
master | EncodeArgs |
netcoreapp3.1 | 54.1μs | 27.3ns | 98.6ns | 0.432 | 0 | 0 | 32.4 KB |
master | EncodeArgs |
net472 | 66.4μs | 25.8ns | 100ns | 5.14 | 0.0663 | 0 | 32.5 KB |
master | EncodeLegacyArgs |
net6.0 | 73.1μs | 58ns | 225ns | 0 | 0 | 0 | 2.14 KB |
master | EncodeLegacyArgs |
netcoreapp3.1 | 104μs | 116ns | 420ns | 0 | 0 | 0 | 2.14 KB |
master | EncodeLegacyArgs |
net472 | 154μs | 78.6ns | 304ns | 0.305 | 0 | 0 | 2.15 KB |
#6185 | EncodeArgs |
net6.0 | 37.3μs | 19.6ns | 75.8ns | 0.447 | 0 | 0 | 32.4 KB |
#6185 | EncodeArgs |
netcoreapp3.1 | 54μs | 18.8ns | 70.4ns | 0.431 | 0 | 0 | 32.4 KB |
#6185 | EncodeArgs |
net472 | 68.7μs | 36.2ns | 140ns | 5.15 | 0.0692 | 0 | 32.5 KB |
#6185 | EncodeLegacyArgs |
net6.0 | 73.7μs | 68.1ns | 264ns | 0 | 0 | 0 | 2.14 KB |
#6185 | EncodeLegacyArgs |
netcoreapp3.1 | 107μs | 226ns | 877ns | 0 | 0 | 0 | 2.14 KB |
#6185 | EncodeLegacyArgs |
net472 | 152μs | 91.2ns | 353ns | 0.305 | 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 | 184μs | 109ns | 407ns | 0 | 0 | 0 | 2.44 KB |
master | RunWafRealisticBenchmark |
netcoreapp3.1 | 194μs | 252ns | 978ns | 0 | 0 | 0 | 2.39 KB |
master | RunWafRealisticBenchmark |
net472 | 209μs | 123ns | 475ns | 0.314 | 0 | 0 | 2.46 KB |
master | RunWafRealisticBenchmarkWithAttack |
net6.0 | 123μs | 268ns | 1.04μs | 0 | 0 | 0 | 1.47 KB |
master | RunWafRealisticBenchmarkWithAttack |
netcoreapp3.1 | 130μs | 183ns | 685ns | 0 | 0 | 0 | 1.46 KB |
master | RunWafRealisticBenchmarkWithAttack |
net472 | 140μs | 76.8ns | 298ns | 0.207 | 0 | 0 | 1.49 KB |
#6185 | RunWafRealisticBenchmark |
net6.0 | 185μs | 141ns | 547ns | 0 | 0 | 0 | 2.44 KB |
#6185 | RunWafRealisticBenchmark |
netcoreapp3.1 | 198μs | 150ns | 539ns | 0 | 0 | 0 | 2.39 KB |
#6185 | RunWafRealisticBenchmark |
net472 | 209μs | 96.9ns | 375ns | 0.314 | 0 | 0 | 2.46 KB |
#6185 | RunWafRealisticBenchmarkWithAttack |
net6.0 | 121μs | 51.3ns | 192ns | 0 | 0 | 0 | 1.47 KB |
#6185 | RunWafRealisticBenchmarkWithAttack |
netcoreapp3.1 | 130μs | 127ns | 493ns | 0 | 0 | 0 | 1.46 KB |
#6185 | RunWafRealisticBenchmarkWithAttack |
net472 | 138μs | 45.6ns | 176ns | 0.207 | 0 | 0 | 1.49 KB |
Benchmarks.Trace.Iast.StringAspectsBenchmark - Same speed ✔️ More allocations ⚠️
More allocations ⚠️ in #6185
Benchmark
Base Allocated
Diff Allocated
Change
Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑net472
59.04 KB
62.11 KB
3.07 KB
5.20%
Fewer allocations 🎉 in #6185
Benchmark
Base Allocated
Diff Allocated
Change
Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0
264.38 KB
255.03 KB
-9.34 KB
-3.53%
Benchmark | Base Allocated | Diff Allocated | Change | Change % |
---|---|---|---|---|
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑net472 | 59.04 KB | 62.11 KB | 3.07 KB | 5.20% |
Benchmark | Base Allocated | Diff Allocated | Change | Change % |
---|---|---|---|---|
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0 | 264.38 KB | 255.03 KB | -9.34 KB | -3.53% |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | StringConcatBenchmark |
net6.0 | 59.7μs | 671ns | 6.61μs | 0 | 0 | 0 | 43.44 KB |
master | StringConcatBenchmark |
netcoreapp3.1 | 53.4μs | 264ns | 1.18μs | 0 | 0 | 0 | 42.64 KB |
master | StringConcatBenchmark |
net472 | 38μs | 166ns | 620ns | 0 | 0 | 0 | 59.04 KB |
master | StringConcatAspectBenchmark |
net6.0 | 311μs | 1.79μs | 13.8μs | 0 | 0 | 0 | 264.38 KB |
master | StringConcatAspectBenchmark |
netcoreapp3.1 | 333μs | 1.48μs | 9.01μs | 0 | 0 | 0 | 253.21 KB |
master | StringConcatAspectBenchmark |
net472 | 280μs | 6.72μs | 64.4μs | 0 | 0 | 0 | 278.53 KB |
#6185 | StringConcatBenchmark |
net6.0 | 62.4μs | 919ns | 9.05μs | 0 | 0 | 0 | 43.44 KB |
#6185 | StringConcatBenchmark |
netcoreapp3.1 | 60.5μs | 777ns | 7.61μs | 0 | 0 | 0 | 42.64 KB |
#6185 | StringConcatBenchmark |
net472 | 36.2μs | 83.3ns | 312ns | 0 | 0 | 0 | 62.11 KB |
#6185 | StringConcatAspectBenchmark |
net6.0 | 313μs | 1.76μs | 12.4μs | 0 | 0 | 0 | 255.03 KB |
#6185 | StringConcatAspectBenchmark |
netcoreapp3.1 | 333μs | 1.78μs | 12.8μs | 0 | 0 | 0 | 252.01 KB |
#6185 | StringConcatAspectBenchmark |
net472 | 285μs | 6.36μs | 62.3μs | 0 | 0 | 0 | 278.53 KB |
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 (6185) (11.102M) : 0, 11101866
master (11.141M) : 0, 11140719
benchmarks/2.9.0 (11.081M) : 0, 11080577
section Automatic
This PR (6185) (7.410M) : 0, 7410119
master (7.280M) : 0, 7279870
benchmarks/2.9.0 (7.732M) : 0, 7732233
section Trace stats
master (7.669M) : 0, 7668885
section Manual
master (11.075M) : 0, 11074558
section Manual + Automatic
This PR (6185) (6.857M) : 0, 6856882
master (6.727M) : 0, 6727438
section DD_TRACE_ENABLED=0
master (10.143M) : 0, 10143410
gantt
title Throughput Linux arm64 (Total requests)
dateFormat X
axisFormat %s
section Baseline
This PR (6185) (9.706M) : 0, 9705798
master (9.575M) : 0, 9575114
benchmarks/2.9.0 (9.798M) : 0, 9798067
section Automatic
This PR (6185) (6.638M) : 0, 6637652
master (6.573M) : 0, 6573227
section Trace stats
master (6.889M) : 0, 6888898
section Manual
master (9.554M) : 0, 9554430
section Manual + Automatic
This PR (6185) (6.147M) : 0, 6147334
master (6.223M) : 0, 6222792
section DD_TRACE_ENABLED=0
master (8.834M) : 0, 8833554
gantt
title Throughput Windows x64 (Total requests)
dateFormat X
axisFormat %s
section Baseline
This PR (6185) (9.712M) : 0, 9712037
master (10.041M) : 0, 10040592
benchmarks/2.9.0 (10.067M) : 0, 10067315
section Automatic
This PR (6185) (6.353M) : 0, 6353447
master (6.448M) : 0, 6447976
benchmarks/2.9.0 (7.552M) : 0, 7552193
section Trace stats
master (7.067M) : 0, 7067450
section Manual
master (9.677M) : 0, 9676828
section Manual + Automatic
This PR (6185) (5.841M) : 0, 5841429
master (6.140M) : 0, 6140399
section DD_TRACE_ENABLED=0
master (9.137M) : 0, 9137058
|
Benchmarks Report for tracer 🐌Benchmarks for #6185 compared to master:
The following thresholds were used for comparing the benchmark speeds:
Allocation changes below 0.5% are ignored. Benchmark detailsBenchmarks.Trace.ActivityBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.AspNetCoreBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.DbCommandBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.ElasticsearchBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.GraphQLBenchmark - Slower
|
Benchmark | diff/base | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.GraphQLBenchmark.ExecuteAsync‑net6.0 | 1.146 | 1,237.27 | 1,418.02 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | ExecuteAsync |
net6.0 | 1.24μs | 1.01ns | 3.76ns | 0.0136 | 0 | 0 | 952 B |
master | ExecuteAsync |
netcoreapp3.1 | 1.63μs | 0.76ns | 2.84ns | 0.0121 | 0 | 0 | 952 B |
master | ExecuteAsync |
net472 | 1.86μs | 0.866ns | 3.35ns | 0.145 | 0 | 0 | 915 B |
#6185 | ExecuteAsync |
net6.0 | 1.42μs | 0.959ns | 3.72ns | 0.0135 | 0 | 0 | 952 B |
#6185 | ExecuteAsync |
netcoreapp3.1 | 1.66μs | 0.979ns | 3.79ns | 0.0124 | 0 | 0 | 952 B |
#6185 | ExecuteAsync |
net472 | 1.71μs | 0.556ns | 2.08ns | 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.16μs | 1.11ns | 4.29ns | 0.0316 | 0 | 0 | 2.22 KB |
master | SendAsync |
netcoreapp3.1 | 5.11μs | 1.86ns | 6.96ns | 0.0357 | 0 | 0 | 2.76 KB |
master | SendAsync |
net472 | 7.83μs | 3.78ns | 14.6ns | 0.497 | 0 | 0 | 3.15 KB |
#6185 | SendAsync |
net6.0 | 4.17μs | 2.54ns | 8.79ns | 0.0311 | 0 | 0 | 2.22 KB |
#6185 | SendAsync |
netcoreapp3.1 | 5.09μs | 2.13ns | 7.99ns | 0.0354 | 0 | 0 | 2.76 KB |
#6185 | SendAsync |
net472 | 7.74μs | 2.54ns | 9.85ns | 0.5 | 0 | 0 | 3.15 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 | 1.44μs | 0.626ns | 2.42ns | 0.023 | 0 | 0 | 1.64 KB |
master | EnrichedLog |
netcoreapp3.1 | 2.21μs | 1.04ns | 3.9ns | 0.021 | 0 | 0 | 1.64 KB |
master | EnrichedLog |
net472 | 2.54μs | 1.3ns | 4.88ns | 0.249 | 0 | 0 | 1.57 KB |
#6185 | EnrichedLog |
net6.0 | 1.54μs | 0.592ns | 2.22ns | 0.0227 | 0 | 0 | 1.64 KB |
#6185 | EnrichedLog |
netcoreapp3.1 | 2.21μs | 1.1ns | 4.12ns | 0.0223 | 0 | 0 | 1.64 KB |
#6185 | EnrichedLog |
net472 | 2.59μs | 1.3ns | 5.04ns | 0.249 | 0 | 0 | 1.57 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 | 118μs | 229ns | 885ns | 0.0586 | 0 | 0 | 4.28 KB |
master | EnrichedLog |
netcoreapp3.1 | 122μs | 329ns | 1.28μs | 0 | 0 | 0 | 4.28 KB |
master | EnrichedLog |
net472 | 152μs | 190ns | 736ns | 0.688 | 0.229 | 0 | 4.46 KB |
#6185 | EnrichedLog |
net6.0 | 116μs | 232ns | 897ns | 0.0587 | 0 | 0 | 4.28 KB |
#6185 | EnrichedLog |
netcoreapp3.1 | 122μs | 102ns | 353ns | 0.0605 | 0 | 0 | 4.28 KB |
#6185 | EnrichedLog |
net472 | 153μs | 105ns | 392ns | 0.687 | 0.229 | 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μs | 1.39ns | 5.39ns | 0.03 | 0 | 0 | 2.2 KB |
master | EnrichedLog |
netcoreapp3.1 | 4.06μs | 1.52ns | 5.49ns | 0.0284 | 0 | 0 | 2.2 KB |
master | EnrichedLog |
net472 | 4.9μs | 2.34ns | 9.08ns | 0.319 | 0 | 0 | 2.02 KB |
#6185 | EnrichedLog |
net6.0 | 3.24μs | 1.09ns | 4.09ns | 0.0309 | 0 | 0 | 2.2 KB |
#6185 | EnrichedLog |
netcoreapp3.1 | 4.23μs | 1.67ns | 6.26ns | 0.0294 | 0 | 0 | 2.2 KB |
#6185 | EnrichedLog |
net472 | 4.81μs | 1.93ns | 7.47ns | 0.32 | 0 | 0 | 2.02 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.29μs | 0.712ns | 2.76ns | 0.0161 | 0 | 0 | 1.14 KB |
master | SendReceive |
netcoreapp3.1 | 1.81μs | 3.17ns | 12.3ns | 0.0152 | 0 | 0 | 1.14 KB |
master | SendReceive |
net472 | 2.21μs | 1.25ns | 4.69ns | 0.183 | 0.0011 | 0 | 1.16 KB |
#6185 | SendReceive |
net6.0 | 1.29μs | 0.53ns | 1.91ns | 0.0162 | 0 | 0 | 1.14 KB |
#6185 | SendReceive |
netcoreapp3.1 | 1.74μs | 0.838ns | 3.25ns | 0.0156 | 0 | 0 | 1.14 KB |
#6185 | SendReceive |
net472 | 2.06μs | 1.78ns | 6.9ns | 0.183 | 0.00103 | 0 | 1.16 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.78μs | 7.85ns | 30.4ns | 0.0219 | 0 | 0 | 1.6 KB |
master | EnrichedLog |
netcoreapp3.1 | 3.88μs | 1.34ns | 5.21ns | 0.0213 | 0 | 0 | 1.65 KB |
master | EnrichedLog |
net472 | 4.33μs | 2.64ns | 10.2ns | 0.323 | 0 | 0 | 2.04 KB |
#6185 | EnrichedLog |
net6.0 | 2.84μs | 0.94ns | 3.64ns | 0.0226 | 0 | 0 | 1.6 KB |
#6185 | EnrichedLog |
netcoreapp3.1 | 3.84μs | 2.25ns | 8.73ns | 0.023 | 0 | 0 | 1.65 KB |
#6185 | EnrichedLog |
net472 | 4.29μs | 3.78ns | 14.6ns | 0.323 | 0 | 0 | 2.04 KB |
Benchmarks.Trace.SpanBenchmark - Slower ⚠️ Same allocations ✔️
Slower ⚠️ in #6185
Benchmark
diff/base
Base Median (ns)
Diff Median (ns)
Modality
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑netcoreapp3.1
1.123
538.06
604.24
Benchmark | diff/base | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑netcoreapp3.1 | 1.123 | 538.06 | 604.24 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | StartFinishSpan |
net6.0 | 407ns | 0.0899ns | 0.348ns | 0.00799 | 0 | 0 | 576 B |
master | StartFinishSpan |
netcoreapp3.1 | 538ns | 0.299ns | 1.12ns | 0.00757 | 0 | 0 | 576 B |
master | StartFinishSpan |
net472 | 731ns | 0.351ns | 1.36ns | 0.0917 | 0 | 0 | 578 B |
master | StartFinishScope |
net6.0 | 572ns | 0.311ns | 1.2ns | 0.00972 | 0 | 0 | 696 B |
master | StartFinishScope |
netcoreapp3.1 | 726ns | 0.447ns | 1.73ns | 0.00942 | 0 | 0 | 696 B |
master | StartFinishScope |
net472 | 947ns | 0.496ns | 1.92ns | 0.104 | 0 | 0 | 658 B |
#6185 | StartFinishSpan |
net6.0 | 412ns | 0.102ns | 0.395ns | 0.00805 | 0 | 0 | 576 B |
#6185 | StartFinishSpan |
netcoreapp3.1 | 604ns | 0.31ns | 1.2ns | 0.00781 | 0 | 0 | 576 B |
#6185 | StartFinishSpan |
net472 | 743ns | 1.06ns | 4.1ns | 0.0916 | 0 | 0 | 578 B |
#6185 | StartFinishScope |
net6.0 | 570ns | 0.189ns | 0.683ns | 0.00985 | 0 | 0 | 696 B |
#6185 | StartFinishScope |
netcoreapp3.1 | 711ns | 0.273ns | 0.945ns | 0.00923 | 0 | 0 | 696 B |
#6185 | StartFinishScope |
net472 | 949ns | 0.607ns | 2.35ns | 0.104 | 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 | 647ns | 0.343ns | 1.33ns | 0.00989 | 0 | 0 | 696 B |
master | RunOnMethodBegin |
netcoreapp3.1 | 1.02μs | 1.65ns | 6.41ns | 0.00908 | 0 | 0 | 696 B |
master | RunOnMethodBegin |
net472 | 1.13μs | 1.16ns | 4.51ns | 0.104 | 0 | 0 | 658 B |
#6185 | RunOnMethodBegin |
net6.0 | 652ns | 0.461ns | 1.79ns | 0.00986 | 0 | 0 | 696 B |
#6185 | RunOnMethodBegin |
netcoreapp3.1 | 966ns | 1.1ns | 4.26ns | 0.00921 | 0 | 0 | 696 B |
#6185 | RunOnMethodBegin |
net472 | 1.18μs | 0.386ns | 1.49ns | 0.104 | 0 | 0 | 658 B |
c96ebc6
to
23de289
Compare
Summary of changes
Some HttpRequestValidationExceptions were detected when accessing the property httpRequest.Form or when accessing individual to values within a NamevalueCollection. This is something that can happen when accessing these values with the validation mechanisms enabled within the request. It only applies to .net framework.
In the past, similar exceptions were addressed by using the class ReuqestDataHelper. Some new methods have been added to handle this kind of situations.
Reason for change
Implementation details
Test coverage
Other details