-
Notifications
You must be signed in to change notification settings - Fork 145
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
Add TelemetryMetric to SetTag and remove GetTagObject #4389
Conversation
Datadog ReportBranch report: ✅ |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM on the metrics front, thanks 👍 Though I still dislike the GetTagObject()
method, do we have to have it? 😛
@@ -119,6 +121,8 @@ public static ISpan SetTag(this ISpan span, string key, double? value) | |||
[PublicApi] | |||
public static object GetTagObject(this ISpan span, string key) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I still really don't like this as an API, do we have to add it? I get customers wanting to add the metric, but do they really need to get it? And if so, could we call this GetNumericTag(string)
(or something) and only get from metrics, seeing as we already have a GetTag(string)
method?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really don’t need it but it feels weird having a setter without the getter. I guess we can remove it and wait for someone asking for it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we can remove it and wait for someone asking for it
Personally I'd prefer that, because once we add it, we can never remove it.
I hate public APIs 😛
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with Andrew that we should limit ourselves to the strict minimum irt to public API
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 (4389) - mean (3,002ms) : 2926, 3079
. : milestone, 3002,
master - mean (2,988ms) : 2892, 3084
. : milestone, 2988,
section CallTarget+Inlining+NGEN
This PR (4389) - mean (3,832ms) : 3764, 3900
. : milestone, 3832,
master - mean (3,853ms) : 3753, 3953
. : milestone, 3853,
gantt
title Execution time (ms) FakeDbCommand (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (4389) - mean (3,120ms) : 3000, 3240
. : milestone, 3120,
master - mean (3,118ms) : 3046, 3190
. : milestone, 3118,
section CallTarget+Inlining+NGEN
This PR (4389) - mean (3,631ms) : 3568, 3694
. : milestone, 3631,
master - mean (3,632ms) : 3581, 3683
. : milestone, 3632,
gantt
title Execution time (ms) FakeDbCommand (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (4389) - mean (3,120ms) : 3031, 3209
. : milestone, 3120,
master - mean (3,085ms) : 2989, 3181
. : milestone, 3085,
section CallTarget+Inlining+NGEN
This PR (4389) - mean (3,602ms) : 3527, 3676
. : milestone, 3602,
master - mean (3,592ms) : 3522, 3663
. : milestone, 3592,
gantt
title Execution time (ms) HttpMessageHandler (.NET Framework 4.6.2)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (4389) - mean (191ms) : 185, 197
. : milestone, 191,
master - mean (191ms) : 187, 195
. : milestone, 191,
section CallTarget+Inlining+NGEN
This PR (4389) - mean (1,130ms) : 1100, 1161
. : milestone, 1130,
master - mean (1,131ms) : 1105, 1157
. : milestone, 1131,
gantt
title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (4389) - mean (375ms) : 370, 380
. : milestone, 375,
master - mean (374ms) : 369, 379
. : milestone, 374,
section CallTarget+Inlining+NGEN
This PR (4389) - mean (1,206ms) : 1096, 1317
. : milestone, 1206,
master - mean (1,194ms) : 1170, 1218
. : milestone, 1194,
gantt
title Execution time (ms) HttpMessageHandler (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (4389) - mean (362ms) : 357, 367
. : milestone, 362,
master - mean (360ms) : 355, 365
. : milestone, 360,
section CallTarget+Inlining+NGEN
This PR (4389) - mean (1,147ms) : 1117, 1177
. : milestone, 1147,
master - mean (1,140ms) : 1112, 1168
. : milestone, 1140,
|
Benchmarks Report 🐌Benchmarks for #4389 compared to master:
The following thresholds were used for comparing the benchmark speeds:
Allocation changes below 0.5% are ignored. Benchmark detailsBenchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.AppSecBodyBenchmark - Slower
|
Benchmark | diff/base | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.AppSecBodyBenchmark.ObjectExtractorSimpleBody‑net6.0 | 1.283 | 115.05 | 147.60 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | AllCycleSimpleBody |
net6.0 | 39μs | 41ns | 159ns | 0.0197 | 0 | 0 | 1.65 KB |
master | AllCycleSimpleBody |
netcoreapp3.1 | 40.8μs | 86.2ns | 334ns | 0.0204 | 0 | 0 | 1.63 KB |
master | AllCycleSimpleBody |
net472 | 41.8μs | 16.2ns | 60.5ns | 0.249 | 0 | 0 | 1.69 KB |
master | AllCycleMoreComplexBody |
net6.0 | 225μs | 70.3ns | 263ns | 0.11 | 0 | 0 | 9.22 KB |
master | AllCycleMoreComplexBody |
netcoreapp3.1 | 226μs | 111ns | 385ns | 0.114 | 0 | 0 | 9.12 KB |
master | AllCycleMoreComplexBody |
net472 | 238μs | 183ns | 710ns | 1.42 | 0 | 0 | 9.28 KB |
master | ObjectExtractorSimpleBody |
net6.0 | 115ns | 0.0263ns | 0.0985ns | 0.00394 | 0 | 0 | 280 B |
master | ObjectExtractorSimpleBody |
netcoreapp3.1 | 175ns | 0.0415ns | 0.155ns | 0.00372 | 0 | 0 | 272 B |
master | ObjectExtractorSimpleBody |
net472 | 176ns | 1.03ns | 9ns | 0.0446 | 0 | 0 | 281 B |
master | ObjectExtractorMoreComplexBody |
net6.0 | 3μs | 0.746ns | 2.89ns | 0.054 | 0 | 0 | 3.88 KB |
master | ObjectExtractorMoreComplexBody |
netcoreapp3.1 | 3.95μs | 1.29ns | 4.65ns | 0.0514 | 0 | 0 | 3.78 KB |
master | ObjectExtractorMoreComplexBody |
net472 | 4.53μs | 23.4ns | 112ns | 0.618 | 0.00653 | 0 | 3.89 KB |
#4389 | AllCycleSimpleBody |
net6.0 | 38.5μs | 128ns | 495ns | 0.0189 | 0 | 0 | 1.65 KB |
#4389 | AllCycleSimpleBody |
netcoreapp3.1 | 42μs | 120ns | 449ns | 0.0208 | 0 | 0 | 1.63 KB |
#4389 | AllCycleSimpleBody |
net472 | 41.8μs | 48.8ns | 189ns | 0.248 | 0 | 0 | 1.69 KB |
#4389 | AllCycleMoreComplexBody |
net6.0 | 225μs | 127ns | 491ns | 0.112 | 0 | 0 | 9.22 KB |
#4389 | AllCycleMoreComplexBody |
netcoreapp3.1 | 229μs | 404ns | 1.56μs | 0.114 | 0 | 0 | 9.12 KB |
#4389 | AllCycleMoreComplexBody |
net472 | 237μs | 56.2ns | 210ns | 1.42 | 0 | 0 | 9.28 KB |
#4389 | ObjectExtractorSimpleBody |
net6.0 | 148ns | 0.06ns | 0.232ns | 0.0039 | 0 | 0 | 280 B |
#4389 | ObjectExtractorSimpleBody |
netcoreapp3.1 | 181ns | 0.0764ns | 0.286ns | 0.00365 | 0 | 0 | 272 B |
#4389 | ObjectExtractorSimpleBody |
net472 | 174ns | 1.02ns | 9.39ns | 0.0446 | 0 | 0 | 281 B |
#4389 | ObjectExtractorMoreComplexBody |
net6.0 | 3.01μs | 0.899ns | 3.24ns | 0.0542 | 0 | 0 | 3.88 KB |
#4389 | ObjectExtractorMoreComplexBody |
netcoreapp3.1 | 4.31μs | 14.2ns | 53ns | 0.0506 | 0 | 0 | 3.78 KB |
#4389 | ObjectExtractorMoreComplexBody |
net472 | 4.52μs | 22.3ns | 94.8ns | 0.617 | 0.0068 | 0 | 3.89 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 | 169μs | 134ns | 518ns | 0.169 | 0 | 0 | 18.03 KB |
master | SendRequest |
netcoreapp3.1 | 187μs | 267ns | 1.03μs | 0.187 | 0 | 0 | 20.09 KB |
master | SendRequest |
net472 | 0.00132ns | 0.000362ns | 0.0014ns | 0 | 0 | 0 | 0 b |
#4389 | SendRequest |
net6.0 | 169μs | 94.4ns | 366ns | 0.253 | 0 | 0 | 18.03 KB |
#4389 | SendRequest |
netcoreapp3.1 | 190μs | 243ns | 840ns | 0.189 | 0 | 0 | 20.09 KB |
#4389 | SendRequest |
net472 | 0.00107ns | 0.000334ns | 0.00129ns | 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 | 523μs | 767ns | 2.77μs | 0.494 | 0 | 0 | 41.52 KB |
master | WriteAndFlushEnrichedTraces |
netcoreapp3.1 | 629μs | 604ns | 2.26μs | 0.322 | 0 | 0 | 41.72 KB |
master | WriteAndFlushEnrichedTraces |
net472 | 770μs | 2.54μs | 9.16μs | 8.28 | 2.64 | 0.377 | 53.23 KB |
#4389 | WriteAndFlushEnrichedTraces |
net6.0 | 497μs | 938ns | 3.63μs | 0.521 | 0 | 0 | 41.49 KB |
#4389 | WriteAndFlushEnrichedTraces |
netcoreapp3.1 | 634μs | 2.07μs | 8.02μs | 0.317 | 0 | 0 | 41.75 KB |
#4389 | WriteAndFlushEnrichedTraces |
net472 | 818μs | 2.94μs | 11.4μs | 8.41 | 2.4 | 0.401 | 53.24 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 | 854ns | 0.288ns | 1.08ns | 0.0102 | 0 | 0 | 720 B |
master | ExecuteNonQuery |
netcoreapp3.1 | 1.2μs | 0.811ns | 3.14ns | 0.00971 | 0 | 0 | 720 B |
master | ExecuteNonQuery |
net472 | 1.4μs | 0.283ns | 1.06ns | 0.108 | 0.000707 | 0 | 682 B |
#4389 | ExecuteNonQuery |
net6.0 | 930ns | 0.402ns | 1.45ns | 0.0102 | 0 | 0 | 720 B |
#4389 | ExecuteNonQuery |
netcoreapp3.1 | 1.18μs | 0.481ns | 1.86ns | 0.00957 | 0 | 0 | 720 B |
#4389 | ExecuteNonQuery |
net472 | 1.46μs | 0.475ns | 1.84ns | 0.108 | 0 | 0 | 682 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 | 967ns | 0.207ns | 0.747ns | 0.0132 | 0 | 0 | 944 B |
master | CallElasticsearch |
netcoreapp3.1 | 1.23μs | 0.437ns | 1.64ns | 0.0129 | 0 | 0 | 944 B |
master | CallElasticsearch |
net472 | 1.95μs | 0.501ns | 1.94ns | 0.151 | 0.000974 | 0 | 955 B |
master | CallElasticsearchAsync |
net6.0 | 1.03μs | 0.343ns | 1.24ns | 0.0131 | 0 | 0 | 920 B |
master | CallElasticsearchAsync |
netcoreapp3.1 | 1.35μs | 0.429ns | 1.61ns | 0.0135 | 0 | 0 | 992 B |
master | CallElasticsearchAsync |
net472 | 2.21μs | 0.672ns | 2.51ns | 0.161 | 0 | 0 | 1.01 KB |
#4389 | CallElasticsearch |
net6.0 | 1μs | 0.384ns | 1.38ns | 0.0131 | 0 | 0 | 944 B |
#4389 | CallElasticsearch |
netcoreapp3.1 | 1.22μs | 0.48ns | 1.73ns | 0.0129 | 0 | 0 | 944 B |
#4389 | CallElasticsearch |
net472 | 2.13μs | 0.449ns | 1.74ns | 0.151 | 0 | 0 | 955 B |
#4389 | CallElasticsearchAsync |
net6.0 | 1μs | 0.376ns | 1.41ns | 0.013 | 0 | 0 | 920 B |
#4389 | CallElasticsearchAsync |
netcoreapp3.1 | 1.29μs | 2.2ns | 8.52ns | 0.0136 | 0 | 0 | 992 B |
#4389 | CallElasticsearchAsync |
net472 | 2.28μs | 0.571ns | 2.06ns | 0.161 | 0.00114 | 0 | 1.01 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.15μs | 0.776ns | 3.01ns | 0.0126 | 0 | 0 | 912 B |
master | ExecuteAsync |
netcoreapp3.1 | 1.43μs | 0.357ns | 1.34ns | 0.0125 | 0 | 0 | 912 B |
master | ExecuteAsync |
net472 | 1.58μs | 0.241ns | 0.901ns | 0.139 | 0.000792 | 0 | 875 B |
#4389 | ExecuteAsync |
net6.0 | 1.11μs | 0.515ns | 1.93ns | 0.0126 | 0 | 0 | 912 B |
#4389 | ExecuteAsync |
netcoreapp3.1 | 1.35μs | 0.596ns | 2.15ns | 0.0122 | 0 | 0 | 912 B |
#4389 | ExecuteAsync |
net472 | 1.6μs | 0.794ns | 3.08ns | 0.138 | 0.000795 | 0 | 875 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 | 3.52μs | 1.18ns | 4.42ns | 0.0265 | 0 | 0 | 1.9 KB |
master | SendAsync |
netcoreapp3.1 | 4.28μs | 1.07ns | 3.71ns | 0.0321 | 0 | 0 | 2.43 KB |
master | SendAsync |
net472 | 6.71μs | 1.79ns | 6.92ns | 0.476 | 0 | 0 | 3 KB |
#4389 | SendAsync |
net6.0 | 3.68μs | 1.24ns | 4.63ns | 0.0256 | 0 | 0 | 1.9 KB |
#4389 | SendAsync |
netcoreapp3.1 | 4.29μs | 1.56ns | 5.82ns | 0.0322 | 0 | 0 | 2.43 KB |
#4389 | SendAsync |
net472 | 6.84μs | 2.1ns | 7.87ns | 0.475 | 0 | 0 | 3 KB |
Benchmarks.Trace.ILoggerBenchmark - Faster 🎉 Same allocations ✔️
Faster 🎉 in #4389
Benchmark
base/diff
Base Median (ns)
Diff Median (ns)
Modality
Benchmarks.Trace.ILoggerBenchmark.EnrichedLog‑netcoreapp3.1
1.124
2,034.89
1,809.68
Benchmark | base/diff | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.ILoggerBenchmark.EnrichedLog‑netcoreapp3.1 | 1.124 | 2,034.89 | 1,809.68 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | EnrichedLog |
net6.0 | 1.24μs | 0.696ns | 2.6ns | 0.023 | 0 | 0 | 1.62 KB |
master | EnrichedLog |
netcoreapp3.1 | 2.05μs | 5.4ns | 20.9ns | 0.0216 | 0 | 0 | 1.62 KB |
master | EnrichedLog |
net472 | 2.26μs | 0.807ns | 2.8ns | 0.245 | 0 | 0 | 1.54 KB |
#4389 | EnrichedLog |
net6.0 | 1.34μs | 0.411ns | 1.59ns | 0.0228 | 0 | 0 | 1.62 KB |
#4389 | EnrichedLog |
netcoreapp3.1 | 1.82μs | 4.07ns | 15.8ns | 0.0217 | 0 | 0 | 1.62 KB |
#4389 | EnrichedLog |
net472 | 2.24μs | 1.98ns | 7.67ns | 0.244 | 0 | 0 | 1.54 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 | 112μs | 206ns | 800ns | 0.0555 | 0 | 0 | 4.21 KB |
master | EnrichedLog |
netcoreapp3.1 | 116μs | 111ns | 431ns | 0 | 0 | 0 | 4.21 KB |
master | EnrichedLog |
net472 | 146μs | 101ns | 379ns | 0.658 | 0.219 | 0 | 4.38 KB |
#4389 | EnrichedLog |
net6.0 | 110μs | 157ns | 609ns | 0.0549 | 0 | 0 | 4.21 KB |
#4389 | EnrichedLog |
netcoreapp3.1 | 115μs | 107ns | 387ns | 0.057 | 0 | 0 | 4.21 KB |
#4389 | EnrichedLog |
net472 | 146μs | 206ns | 798ns | 0.651 | 0.217 | 0 | 4.38 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 | 2.8μs | 1.06ns | 4.1ns | 0.0307 | 0 | 0 | 2.18 KB |
master | EnrichedLog |
netcoreapp3.1 | 3.93μs | 1.91ns | 6.87ns | 0.0294 | 0 | 0 | 2.18 KB |
master | EnrichedLog |
net472 | 4.66μs | 1.75ns | 6.78ns | 0.316 | 0 | 0 | 1.99 KB |
#4389 | EnrichedLog |
net6.0 | 3.19μs | 21.7ns | 202ns | 0.0298 | 0 | 0 | 2.18 KB |
#4389 | EnrichedLog |
netcoreapp3.1 | 3.72μs | 0.563ns | 2.03ns | 0.0279 | 0 | 0 | 2.18 KB |
#4389 | EnrichedLog |
net472 | 4.5μs | 2.88ns | 11.2ns | 0.316 | 0 | 0 | 1.99 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.13μs | 0.508ns | 1.97ns | 0.0157 | 0 | 0 | 1.11 KB |
master | SendReceive |
netcoreapp3.1 | 1.45μs | 0.699ns | 2.52ns | 0.0152 | 0 | 0 | 1.11 KB |
master | SendReceive |
net472 | 1.7μs | 1.7ns | 6.58ns | 0.177 | 0 | 0 | 1.12 KB |
#4389 | SendReceive |
net6.0 | 1.07μs | 0.508ns | 1.97ns | 0.0155 | 0 | 0 | 1.11 KB |
#4389 | SendReceive |
netcoreapp3.1 | 1.4μs | 0.955ns | 3.7ns | 0.0145 | 0 | 0 | 1.11 KB |
#4389 | SendReceive |
net472 | 1.77μs | 1.34ns | 5ns | 0.177 | 0 | 0 | 1.12 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.57μs | 1.19ns | 4.44ns | 0.0206 | 0 | 0 | 1.53 KB |
master | EnrichedLog |
netcoreapp3.1 | 3.5μs | 1.31ns | 4.89ns | 0.021 | 0 | 0 | 1.58 KB |
master | EnrichedLog |
net472 | 3.93μs | 2.69ns | 10.4ns | 0.31 | 0 | 0 | 1.96 KB |
#4389 | EnrichedLog |
net6.0 | 2.52μs | 0.816ns | 3.05ns | 0.0214 | 0 | 0 | 1.53 KB |
#4389 | EnrichedLog |
netcoreapp3.1 | 3.62μs | 1.39ns | 5.02ns | 0.0217 | 0 | 0 | 1.58 KB |
#4389 | EnrichedLog |
net472 | 3.91μs | 2.17ns | 8.12ns | 0.309 | 0 | 0 | 1.96 KB |
Benchmarks.Trace.SpanBenchmark - Slower ⚠️ Same allocations ✔️
Slower ⚠️ in #4389
Benchmark
diff/base
Base Median (ns)
Diff Median (ns)
Modality
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑net472
1.153
615.80
710.19
Faster 🎉 in #4389
Benchmark
base/diff
Base Median (ns)
Diff Median (ns)
Modality
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑netcoreapp3.1
1.181
598.96
507.02
Benchmark | diff/base | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑net472 | 1.153 | 615.80 | 710.19 |
Benchmark | base/diff | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑netcoreapp3.1 | 1.181 | 598.96 | 507.02 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | StartFinishSpan |
net6.0 | 432ns | 0.147ns | 0.55ns | 0.00755 | 0 | 0 | 536 B |
master | StartFinishSpan |
netcoreapp3.1 | 599ns | 0.144ns | 0.558ns | 0.00739 | 0 | 0 | 536 B |
master | StartFinishSpan |
net472 | 616ns | 0.365ns | 1.37ns | 0.0852 | 0 | 0 | 538 B |
master | StartFinishScope |
net6.0 | 557ns | 0.174ns | 0.652ns | 0.0093 | 0 | 0 | 656 B |
master | StartFinishScope |
netcoreapp3.1 | 699ns | 0.284ns | 1.06ns | 0.00884 | 0 | 0 | 656 B |
master | StartFinishScope |
net472 | 806ns | 1.09ns | 4.23ns | 0.0982 | 0 | 0 | 618 B |
#4389 | StartFinishSpan |
net6.0 | 391ns | 0.0964ns | 0.361ns | 0.00746 | 0 | 0 | 536 B |
#4389 | StartFinishSpan |
netcoreapp3.1 | 507ns | 0.227ns | 0.85ns | 0.00715 | 0 | 0 | 536 B |
#4389 | StartFinishSpan |
net472 | 710ns | 0.298ns | 1.15ns | 0.0854 | 0 | 0 | 538 B |
#4389 | StartFinishScope |
net6.0 | 577ns | 0.138ns | 0.515ns | 0.00904 | 0 | 0 | 656 B |
#4389 | StartFinishScope |
netcoreapp3.1 | 735ns | 0.281ns | 1.09ns | 0.00882 | 0 | 0 | 656 B |
#4389 | StartFinishScope |
net472 | 844ns | 0.0756ns | 0.272ns | 0.0978 | 0 | 0 | 618 B |
Benchmarks.Trace.TraceAnnotationsBenchmark - Slower ⚠️ Same allocations ✔️
Slower ⚠️ in #4389
Benchmark
diff/base
Base Median (ns)
Diff Median (ns)
Modality
Benchmarks.Trace.TraceAnnotationsBenchmark.RunOnMethodBegin‑netcoreapp3.1
1.133
761.15
862.54
Benchmark | diff/base | Base Median (ns) | Diff Median (ns) | Modality |
---|---|---|---|---|
Benchmarks.Trace.TraceAnnotationsBenchmark.RunOnMethodBegin‑netcoreapp3.1 | 1.133 | 761.15 | 862.54 |
Raw results
Branch | Method | Toolchain | Mean | StdError | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
---|---|---|---|---|---|---|---|---|---|
master | RunOnMethodBegin |
net6.0 | 578ns | 0.283ns | 1.02ns | 0.00931 | 0 | 0 | 656 B |
master | RunOnMethodBegin |
netcoreapp3.1 | 761ns | 0.331ns | 1.28ns | 0.00888 | 0 | 0 | 656 B |
master | RunOnMethodBegin |
net472 | 897ns | 0.429ns | 1.66ns | 0.0982 | 0 | 0 | 618 B |
#4389 | RunOnMethodBegin |
net6.0 | 591ns | 0.181ns | 0.677ns | 0.00914 | 0 | 0 | 656 B |
#4389 | RunOnMethodBegin |
netcoreapp3.1 | 862ns | 0.307ns | 1.11ns | 0.00882 | 0 | 0 | 656 B |
#4389 | RunOnMethodBegin |
net472 | 896ns | 1.02ns | 3.97ns | 0.0978 | 0 | 0 | 618 B |
Throughput/Crank Report:zap: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 (4389) (11.181M) : 0, 11180590
master (10.902M) : 0, 10901521
benchmarks/2.33.0 (10.950M) : 0, 10949608
benchmarks/2.9.0 (10.949M) : 0, 10948638
section Automatic
This PR (4389) (7.783M) : 0, 7783294
master (7.534M) : 0, 7533509
benchmarks/2.33.0 (7.621M) : 0, 7620707
benchmarks/2.9.0 (7.869M) : 0, 7869138
section Trace stats
master (7.595M) : 0, 7595057
benchmarks/2.33.0 (7.602M) : 0, 7602038
section Manual
This PR (4389) (9.853M) : 0, 9853411
master (9.815M) : 0, 9814905
benchmarks/2.33.0 (9.770M) : 0, 9770235
section Manual + Automatic
This PR (4389) (7.404M) : 0, 7403610
master (7.255M) : 0, 7254836
benchmarks/2.33.0 (7.189M) : 0, 7188658
section Version Conflict
master (6.579M) : 0, 6579121
benchmarks/2.33.0 (6.553M) : 0, 6553316
gantt
title Throughput Linux arm64 (Total requests)
dateFormat X
axisFormat %s
section Baseline
This PR (4389) (9.431M) : 0, 9431032
master (9.667M) : 0, 9666802
benchmarks/2.33.0 (9.426M) : 0, 9425603
benchmarks/2.9.0 (9.651M) : 0, 9650936
section Automatic
This PR (4389) (6.733M) : 0, 6732726
master (6.755M) : 0, 6754566
benchmarks/2.33.0 (6.803M) : 0, 6802932
section Trace stats
master (6.777M) : 0, 6776538
benchmarks/2.33.0 (6.810M) : 0, 6810447
section Manual
This PR (4389) (8.685M) : 0, 8685238
master (8.561M) : 0, 8561047
benchmarks/2.33.0 (8.435M) : 0, 8434569
section Manual + Automatic
This PR (4389) (6.401M) : 0, 6400775
master (6.332M) : 0, 6331957
benchmarks/2.33.0 (6.465M) : 0, 6465149
section Version Conflict
master (5.975M) : 0, 5975266
benchmarks/2.33.0 (5.807M) : 0, 5806690
gantt
title Throughput Windows x64 (Total requests)
dateFormat X
axisFormat %s
section Baseline
This PR (4389) (10.562M) : 0, 10562113
master (10.104M) : 0, 10103707
benchmarks/2.33.0 (9.426M) : 0, 9426080
benchmarks/2.9.0 (9.867M) : 0, 9866970
section Automatic
This PR (4389) (7.459M) : 0, 7458678
master (6.982M) : 0, 6982306
benchmarks/2.33.0 (6.469M) : 0, 6468939
benchmarks/2.9.0 (7.247M) : 0, 7247453
section Trace stats
master (7.247M) : 0, 7246697
benchmarks/2.33.0 (6.830M) : 0, 6830314
section Manual
This PR (4389) (9.462M) : 0, 9461997
master (9.251M) : 0, 9251104
benchmarks/2.33.0 (8.108M) : 0, 8108026
section Manual + Automatic
This PR (4389) (7.464M) : 0, 7464142
master (6.956M) : 0, 6956130
benchmarks/2.33.0 (6.856M) : 0, 6856379
section Version Conflict
master (6.380M) : 0, 6380435
benchmarks/2.33.0 (5.893M) : 0, 5893016
gantt
title Throughput Linux x64 (ASM) (Total requests)
dateFormat X
axisFormat %s
section Baseline
This PR (4389) (7.676M) : 0, 7675725
master (7.605M) : 0, 7605248
benchmarks/2.33.0 (7.765M) : 0, 7764607
benchmarks/2.9.0 (8.067M) : 0, 8066743
section No attack
This PR (4389) (2.219M) : 0, 2219423
master (2.207M) : 0, 2207340
benchmarks/2.33.0 (2.209M) : 0, 2208725
benchmarks/2.9.0 (3.337M) : 0, 3336566
section Attack
This PR (4389) (1.913M) : 0, 1912806
master (1.918M) : 0, 1917897
benchmarks/2.33.0 (1.911M) : 0, 1910909
benchmarks/2.9.0 (2.611M) : 0, 2611151
section Blocking
This PR (4389) (3.835M) : 0, 3835421
master (3.854M) : 0, 3854094
benchmarks/2.33.0 (3.861M) : 0, 3860900
|
* Add TelemetryMetric to SetTag and GetTagObject * Remove GetTagObject api
Summary of changes
Add telemetry metric to SetTag and GetTagObject extension methods.