-
Notifications
You must be signed in to change notification settings - Fork 141
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 smoke test for config builder instrumentation issue #6224
Conversation
tracer/test/test-applications/aspnet/Samples.AspNet.MultipleAppsInDomain/Web.config
Dismissed
Show dismissed
Hide dismissed
Datadog ReportBranch report: ✅ 0 Failed, 369352 Passed, 2100 Skipped, 14h 53m 45.83s Total Time |
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 (6224) - mean (70ms) : 68, 73
. : milestone, 70,
master - mean (70ms) : 68, 72
. : milestone, 70,
section CallTarget+Inlining+NGEN
This PR (6224) - mean (1,118ms) : 1095, 1141
. : milestone, 1118,
master - mean (1,119ms) : 1098, 1141
. : milestone, 1119,
gantt
title Execution time (ms) FakeDbCommand (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6224) - mean (110ms) : 106, 114
. : milestone, 110,
master - mean (110ms) : 107, 114
. : milestone, 110,
section CallTarget+Inlining+NGEN
This PR (6224) - mean (780ms) : 764, 795
. : milestone, 780,
master - mean (782ms) : 763, 801
. : milestone, 782,
gantt
title Execution time (ms) FakeDbCommand (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6224) - mean (93ms) : 90, 96
. : milestone, 93,
master - mean (93ms) : 90, 96
. : milestone, 93,
section CallTarget+Inlining+NGEN
This PR (6224) - mean (733ms) : 714, 752
. : milestone, 733,
master - mean (738ms) : 722, 753
. : milestone, 738,
gantt
title Execution time (ms) HttpMessageHandler (.NET Framework 4.6.2)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6224) - mean (196ms) : 193, 199
. : milestone, 196,
master - mean (190ms) : 188, 193
. : milestone, 190,
section CallTarget+Inlining+NGEN
This PR (6224) - mean (1,260ms) : 1235, 1286
. : milestone, 1260,
master - mean (1,225ms) : 1202, 1248
. : milestone, 1225,
gantt
title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6224) - mean (285ms) : 280, 290
. : milestone, 285,
master - mean (287ms) : 257, 317
. : milestone, 287,
section CallTarget+Inlining+NGEN
This PR (6224) - mean (983ms) : 967, 1000
. : milestone, 983,
master - mean (952ms) : 931, 973
. : milestone, 952,
gantt
title Execution time (ms) HttpMessageHandler (.NET 6)
dateFormat X
axisFormat %s
todayMarker off
section Baseline
This PR (6224) - mean (272ms) : 267, 277
. : milestone, 272,
master - mean (265ms) : 261, 269
. : milestone, 265,
section CallTarget+Inlining+NGEN
This PR (6224) - mean (965ms) : 945, 984
. : milestone, 965,
master - mean (953ms) : 917, 990
. : milestone, 953,
|
Benchmarks Report for tracer 🐌Benchmarks for #6224 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 - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.HttpClientBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.ILoggerBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.Log4netBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.NLogBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.RedisBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.SerilogBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.SpanBenchmark - Same speed ✔️ Same allocations ✔️Raw results
Benchmarks.Trace.TraceAnnotationsBenchmark - Same speed ✔️ Same allocations ✔️Raw results
|
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.
You could have simplified the config builder, but whatever
#pragma warning disable CS1591 // No xml comments for tag literals. | ||
#pragma warning restore CS1591 // No xml comments for tag literals. |
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.
:stare:
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 wanted a "faithful reproduction" of the issue. This seemed critical 😉
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
// Also, this is a synchronous method. And in single-threaded contexts like ASP.Net | ||
// it can be bad/dangerous to block on async calls. So lets work some TPL voodoo | ||
// to avoid potential deadlocks. | ||
return Task.Run(async () => { return await GetValueAsync(key, string.Empty); }).Result?.Value; |
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.
Wow you decided to keep this
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 won't hide their shame
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
...ations/aspnet/Samples.AspNet.MultipleAppsInDomain/CustomConfigBuilder/CustomConfigBuilder.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: Kevin Gosse <[email protected]>
Summary of changes
Adds a smoke test for the issue fixed in #6147
Reason for change
The issue in #6147 is complex and subtle, with a high risk of regression, so we want to have smoke tests to catch it`
Implementation details
Add a sample app very similar to the one tested with in #6147. Without the fix, the test fails with
After the fix (now merged) the tests pass
Test coverage
This is primarily a smoke test, so we confirm
Other details
For some reason, I had massive issues getting the app to "recognize" the
DD_TRACE_AGENT_URL=http://test-agent.windows:8126
env var setting that's required to talk to the test agent. I have no idea why, and the only resolution I could find was to use powershell to set the variables inside the docker image