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

[CI Visibility] UDS and NamedPipes support #5634

Merged
merged 25 commits into from
Jun 7, 2024

Conversation

tonyredondo
Copy link
Member

@tonyredondo tonyredondo commented May 31, 2024

Summary of changes

This PR adds UDS and Windows Named Pipes transport support for CI Visibility

Reason for change

The feature is supported in APM but missing in CI Visibility

Implementation details

Copied the apm code and adapt it to the Ci Visibility Case

Test coverage

Two new UdsXUnitTest and PipesXUnitTest were added as copy of XUnitTest but using different transports.
Same with UdsXunitEvpTests

Other details

@tonyredondo tonyredondo self-assigned this May 31, 2024
@tonyredondo tonyredondo marked this pull request as ready for review May 31, 2024 14:54
@tonyredondo tonyredondo requested review from a team as code owners May 31, 2024 14:54
@DataDog DataDog deleted a comment from datadog-ddstaging bot May 31, 2024
@DataDog DataDog deleted a comment from andrewlock May 31, 2024
@DataDog DataDog deleted a comment from andrewlock May 31, 2024
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 in general, mostly just suggest some tidying up in the tests to reduce duplication

Comment on lines 435 to 436
case TracesTransportType.WindowsNamedPipe:
Log.Information<string?, int>("Using " + nameof(NamedPipeClientStreamFactory) + " for CI Visibility transport, with pipe name {TracesPipeName} and timeout {TracesPipeTimeoutMs}ms.", exporterSettings.TracesPipeNameInternal, exporterSettings.TracesPipeTimeoutMsInternal);
Copy link
Member

Choose a reason for hiding this comment

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

Is this identical to the default Agent strategy? Can't you use AgentTransportStrategy if so? What's different here? 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

The AutomaticDescompression part and the custom timeout I think.

Copy link
Member Author

Choose a reason for hiding this comment

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

Changed in 8a129d8 to reuse the strategy if is not tcp

Copy link
Member

Choose a reason for hiding this comment

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

Could I suggest an alternative? Just add support for the automatic decompression and custom timeout to the default strategy?

@DataDog DataDog deleted a comment from andrewlock May 31, 2024
@DataDog DataDog deleted a comment from andrewlock May 31, 2024
@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 3, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 3, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 3, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 3, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 3, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 3, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 3, 2024
@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 3, 2024
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.

Nice 👍 Just one small suggestion about extending the default agent strategy instead of conditionally calling it. Could always do that in a separate PR if you agree though

@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 3, 2024
@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 5, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 5, 2024
@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 5, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 5, 2024
@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 6, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 6, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 6, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 6, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 7, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 7, 2024
@DataDog DataDog deleted a comment from andrewlock Jun 7, 2024
@DataDog DataDog deleted a comment from datadog-ddstaging bot Jun 7, 2024
@andrewlock
Copy link
Member

andrewlock commented Jun 7, 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 (5634) - mean (72ms)  : 64, 81
     .   : milestone, 72,
    master - mean (75ms)  : 61, 90
     .   : milestone, 75,

    section CallTarget+Inlining+NGEN
    This PR (5634) - mean (976ms)  : 957, 995
     .   : milestone, 976,
    master - mean (978ms)  : 947, 1010
     .   : milestone, 978,

Loading
gantt
    title Execution time (ms) FakeDbCommand (.NET Core 3.1) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5634) - mean (109ms)  : 106, 112
     .   : milestone, 109,
    master - mean (109ms)  : 107, 112
     .   : milestone, 109,

    section CallTarget+Inlining+NGEN
    This PR (5634) - mean (683ms)  : 660, 706
     .   : milestone, 683,
    master - mean (688ms)  : 669, 707
     .   : milestone, 688,

Loading
gantt
    title Execution time (ms) FakeDbCommand (.NET 6) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5634) - mean (93ms)  : 90, 96
     .   : milestone, 93,
    master - mean (93ms)  : 90, 96
     .   : milestone, 93,

    section CallTarget+Inlining+NGEN
    This PR (5634) - mean (644ms)  : 617, 670
     .   : milestone, 644,
    master - mean (643ms)  : 622, 663
     .   : milestone, 643,

Loading
gantt
    title Execution time (ms) HttpMessageHandler (.NET Framework 4.6.2) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5634) - mean (192ms)  : 186, 197
     .   : milestone, 192,
    master - mean (192ms)  : 188, 196
     .   : milestone, 192,

    section CallTarget+Inlining+NGEN
    This PR (5634) - mean (1,072ms)  : 1047, 1097
     .   : milestone, 1072,
    master - mean (1,066ms)  : 1041, 1090
     .   : milestone, 1066,

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

    section CallTarget+Inlining+NGEN
    This PR (5634) - mean (860ms)  : 839, 882
     .   : milestone, 860,
    master - mean (864ms)  : 840, 888
     .   : milestone, 864,

Loading
gantt
    title Execution time (ms) HttpMessageHandler (.NET 6) 
    dateFormat  X
    axisFormat %s
    todayMarker off
    section Baseline
    This PR (5634) - mean (266ms)  : 262, 269
     .   : milestone, 266,
    master - mean (266ms)  : 262, 270
     .   : milestone, 266,

    section CallTarget+Inlining+NGEN
    This PR (5634) - mean (852ms)  : 824, 880
     .   : milestone, 852,
    master - mean (855ms)  : 828, 881
     .   : milestone, 855,

Loading

@andrewlock
Copy link
Member

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 (5634) (11.866M)   : 0, 11866204
    master (11.793M)   : 0, 11792642
    benchmarks/2.9.0 (11.919M)   : 0, 11919161

    section Automatic
    This PR (5634) (8.068M)   : 0, 8068286
    master (8.100M)   : 0, 8100271
    benchmarks/2.9.0 (8.337M)   : 0, 8336508

    section Trace stats
    master (8.392M)   : 0, 8391668

    section Manual
    This PR (5634) (10.403M)   : 0, 10403094
    master (10.382M)   : 0, 10382409

    section Manual + Automatic
    This PR (5634) (7.674M)   : 0, 7673613
    master (7.604M)   : 0, 7604410

    section Version Conflict
    master (6.895M)   : 0, 6894993

Loading
gantt
    title Throughput Linux arm64 (Total requests) 
    dateFormat  X
    axisFormat %s
    section Baseline
    This PR (5634) (9.709M)   : 0, 9708502
    master (9.469M)   : 0, 9469402
    benchmarks/2.9.0 (9.646M)   : 0, 9645709

    section Automatic
    This PR (5634) (6.496M)   : 0, 6496151
    master (6.624M)   : 0, 6624452

    section Trace stats
    master (6.914M)   : 0, 6913938

    section Manual
    This PR (5634) (8.224M)   : 0, 8224423
    master (8.381M)   : 0, 8381087

    section Manual + Automatic
    This PR (5634) (6.286M)   : 0, 6286200
    master (6.165M)   : 0, 6165101

    section Version Conflict
    master (5.727M)   : 0, 5727364

Loading
gantt
    title Throughput Windows x64 (Total requests) 
    dateFormat  X
    axisFormat %s
    section Baseline
    This PR (5634) (9.747M)   : 0, 9747485
    master (9.839M)   : 0, 9839143
    benchmarks/2.9.0 (10.036M)   : 0, 10035695

    section Automatic
    This PR (5634) (6.930M)   : 0, 6930328
    master (6.893M)   : 0, 6892972
    benchmarks/2.9.0 (7.475M)   : 0, 7475419

    section Trace stats
    master (7.392M)   : 0, 7392031

    section Manual
    This PR (5634) (8.597M)   : 0, 8597415
    master (8.678M)   : 0, 8677977

    section Manual + Automatic
    This PR (5634) (6.666M)   : 0, 6666118
    master (6.649M)   : 0, 6648668

    section Version Conflict
    master (6.142M)   : 0, 6142246

Loading

@andrewlock
Copy link
Member

andrewlock commented Jun 7, 2024

Benchmarks Report for tracer 🐌

Benchmarks for #5634 compared to master:

  • 2 benchmarks are faster, with geometric mean 1.171
  • 1 benchmarks are slower, with geometric mean 1.116
  • 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 9.07μs 44ns 192ns 0.0368 0.0184 0 7.68 KB
master StartStopWithChild netcoreapp3.1 11.1μs 50.7ns 203ns 0.0272 0.0109 0 7.77 KB
master StartStopWithChild net472 17.4μs 28.6ns 111ns 1.38 0.351 0.111 8.2 KB
#5634 StartStopWithChild net6.0 8.78μs 40.4ns 146ns 0.0177 0.00885 0 7.68 KB
#5634 StartStopWithChild netcoreapp3.1 11μs 59.4ns 356ns 0.0285 0.0114 0 7.77 KB
#5634 StartStopWithChild net472 17.4μs 45.3ns 175ns 1.36 0.353 0.0948 8.21 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 497μs 420ns 1.63μs 0 0 0 2.7 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 638μs 484ns 1.87μs 0 0 0 2.7 KB
master WriteAndFlushEnrichedTraces net472 845μs 195ns 729ns 0.422 0 0 3.29 KB
#5634 WriteAndFlushEnrichedTraces net6.0 491μs 216ns 835ns 0 0 0 2.7 KB
#5634 WriteAndFlushEnrichedTraces netcoreapp3.1 629μs 265ns 1.03μs 0 0 0 2.7 KB
#5634 WriteAndFlushEnrichedTraces net472 841μs 346ns 1.34μs 0.419 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 120ns 450ns 0.255 0 0 18.44 KB
master SendRequest netcoreapp3.1 192μs 251ns 937ns 0.19 0 0 20.6 KB
master SendRequest net472 0.000135ns 0.0001ns 0.000375ns 0 0 0 0 b
#5634 SendRequest net6.0 171μs 288ns 1.11μs 0.255 0 0 18.44 KB
#5634 SendRequest netcoreapp3.1 191μs 251ns 972ns 0.189 0 0 20.6 KB
#5634 SendRequest net472 0.000235ns 9.01E‑05ns 0.000349ns 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 557μs 311ns 1.2μs 0.551 0 0 41.55 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 655μs 1.58μs 6.12μs 0.324 0 0 41.88 KB
master WriteAndFlushEnrichedTraces net472 846μs 3.75μs 14.5μs 8.45 2.53 0.422 53.26 KB
#5634 WriteAndFlushEnrichedTraces net6.0 544μs 355ns 1.37μs 0.561 0 0 41.65 KB
#5634 WriteAndFlushEnrichedTraces netcoreapp3.1 657μs 1.16μs 4.5μs 0.324 0 0 41.91 KB
#5634 WriteAndFlushEnrichedTraces net472 852μs 4.02μs 16.6μs 8.19 2.59 0.431 53.26 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.09μs 0.533ns 2.06ns 0.0114 0 0 808 B
master ExecuteNonQuery netcoreapp3.1 1.51μs 1.33ns 5.16ns 0.0112 0 0 808 B
master ExecuteNonQuery net472 1.7μs 1.61ns 6.24ns 0.122 0 0 770 B
#5634 ExecuteNonQuery net6.0 1.15μs 0.995ns 3.86ns 0.0115 0 0 808 B
#5634 ExecuteNonQuery netcoreapp3.1 1.39μs 0.824ns 3.19ns 0.0111 0 0 808 B
#5634 ExecuteNonQuery net472 1.79μs 2.31ns 8.96ns 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.29μs 1.2ns 4.5ns 0.0137 0 0 976 B
master CallElasticsearch netcoreapp3.1 1.55μs 0.947ns 3.54ns 0.0131 0 0 976 B
master CallElasticsearch net472 2.48μs 1.66ns 6.43ns 0.157 0 0 995 B
master CallElasticsearchAsync net6.0 1.25μs 1.13ns 4.37ns 0.0131 0 0 952 B
master CallElasticsearchAsync netcoreapp3.1 1.56μs 0.991ns 3.84ns 0.0134 0 0 1.02 KB
master CallElasticsearchAsync net472 2.58μs 0.931ns 3.6ns 0.166 0.00128 0 1.05 KB
#5634 CallElasticsearch net6.0 1.18μs 0.661ns 2.47ns 0.0136 0 0 976 B
#5634 CallElasticsearch netcoreapp3.1 1.5μs 1.05ns 4.06ns 0.0134 0 0 976 B
#5634 CallElasticsearch net472 2.46μs 1.1ns 4.13ns 0.158 0 0 995 B
#5634 CallElasticsearchAsync net6.0 1.29μs 0.918ns 3.56ns 0.0129 0 0 952 B
#5634 CallElasticsearchAsync netcoreapp3.1 1.67μs 1.46ns 5.66ns 0.0133 0 0 1.02 KB
#5634 CallElasticsearchAsync net472 2.63μs 1.95ns 7.54ns 0.166 0 0 1.05 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.27μs 0.503ns 1.88ns 0.0134 0 0 952 B
master ExecuteAsync netcoreapp3.1 1.66μs 0.843ns 3.15ns 0.0124 0 0 952 B
master ExecuteAsync net472 1.79μs 0.726ns 2.72ns 0.145 0 0 915 B
#5634 ExecuteAsync net6.0 1.28μs 2.11ns 8.16ns 0.0133 0 0 952 B
#5634 ExecuteAsync netcoreapp3.1 1.52μs 0.991ns 3.71ns 0.0131 0 0 952 B
#5634 ExecuteAsync net472 1.78μs 0.943ns 3.65ns 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.13μs 0.871ns 3.26ns 0.0309 0 0 2.22 KB
master SendAsync netcoreapp3.1 5.03μs 2.21ns 8.58ns 0.0354 0 0 2.76 KB
master SendAsync net472 7.54μs 3.66ns 13.7ns 0.493 0 0 3.12 KB
#5634 SendAsync net6.0 4.19μs 1.97ns 7.63ns 0.0316 0 0 2.22 KB
#5634 SendAsync netcoreapp3.1 5.11μs 2.08ns 7.79ns 0.0358 0 0 2.76 KB
#5634 SendAsync net472 7.65μs 2.04ns 7.88ns 0.496 0 0 3.12 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.48μs 0.79ns 2.85ns 0.0227 0 0 1.64 KB
master EnrichedLog netcoreapp3.1 2.25μs 2ns 7.23ns 0.0226 0 0 1.64 KB
master EnrichedLog net472 2.58μs 4.25ns 15.3ns 0.25 0 0 1.57 KB
#5634 EnrichedLog net6.0 1.44μs 0.924ns 3.58ns 0.0232 0 0 1.64 KB
#5634 EnrichedLog netcoreapp3.1 2.27μs 1.84ns 6.9ns 0.0218 0 0 1.64 KB
#5634 EnrichedLog net472 2.61μs 3.3ns 12.8ns 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 116μs 206ns 799ns 0.0578 0 0 4.28 KB
master EnrichedLog netcoreapp3.1 121μs 152ns 590ns 0 0 0 4.28 KB
master EnrichedLog net472 151μs 280ns 1.05μs 0.681 0.227 0 4.46 KB
#5634 EnrichedLog net6.0 116μs 95.5ns 358ns 0.0583 0 0 4.28 KB
#5634 EnrichedLog netcoreapp3.1 121μs 192ns 743ns 0 0 0 4.28 KB
#5634 EnrichedLog net472 152μs 165ns 616ns 0.676 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μs 1.21ns 4.7ns 0.0301 0 0 2.2 KB
master EnrichedLog netcoreapp3.1 4.19μs 1.37ns 4.93ns 0.0292 0 0 2.2 KB
master EnrichedLog net472 4.8μs 2.34ns 8.43ns 0.32 0 0 2.02 KB
#5634 EnrichedLog net6.0 3.09μs 0.972ns 3.76ns 0.031 0 0 2.2 KB
#5634 EnrichedLog netcoreapp3.1 4.17μs 1.83ns 6.83ns 0.0292 0 0 2.2 KB
#5634 EnrichedLog net472 4.7μs 1.22ns 4.57ns 0.321 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.26μs 1.27ns 4.9ns 0.0163 0 0 1.14 KB
master SendReceive netcoreapp3.1 1.77μs 1.29ns 4.99ns 0.0151 0 0 1.14 KB
master SendReceive net472 2.11μs 1.29ns 4.66ns 0.183 0 0 1.16 KB
#5634 SendReceive net6.0 1.32μs 0.82ns 3.07ns 0.0158 0 0 1.14 KB
#5634 SendReceive netcoreapp3.1 1.76μs 0.724ns 2.61ns 0.0152 0 0 1.14 KB
#5634 SendReceive net472 2.15μs 2.21ns 8.26ns 0.183 0 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.71μs 0.81ns 3.14ns 0.0227 0 0 1.6 KB
master EnrichedLog netcoreapp3.1 3.91μs 1.81ns 6.79ns 0.0215 0 0 1.65 KB
master EnrichedLog net472 4.41μs 2ns 7.47ns 0.323 0 0 2.04 KB
#5634 EnrichedLog net6.0 2.78μs 0.811ns 3.14ns 0.0222 0 0 1.6 KB
#5634 EnrichedLog netcoreapp3.1 3.87μs 0.8ns 2.88ns 0.0228 0 0 1.65 KB
#5634 EnrichedLog net472 4.46μs 4.46ns 17.3ns 0.323 0 0 2.04 KB
Benchmarks.Trace.SpanBenchmark - Slower ⚠️ Same allocations ✔️

Slower ⚠️ in #5634

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑netcoreapp3.1 1.116 538.53 600.74

Faster 🎉 in #5634

Benchmark base/diff Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑net472 1.198 694.85 580.07
Benchmarks.Trace.SpanBenchmark.StartFinishScope‑netcoreapp3.1 1.144 782.32 683.74

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartFinishSpan net6.0 398ns 0.112ns 0.433ns 0.00817 0 0 576 B
master StartFinishSpan netcoreapp3.1 539ns 0.183ns 0.708ns 0.00767 0 0 576 B
master StartFinishSpan net472 694ns 0.544ns 2.11ns 0.0917 0 0 578 B
master StartFinishScope net6.0 478ns 0.161ns 0.625ns 0.00984 0 0 696 B
master StartFinishScope netcoreapp3.1 783ns 0.287ns 1.07ns 0.00935 0 0 696 B
master StartFinishScope net472 847ns 0.518ns 2.01ns 0.104 0 0 658 B
#5634 StartFinishSpan net6.0 390ns 0.167ns 0.623ns 0.00819 0 0 576 B
#5634 StartFinishSpan netcoreapp3.1 598ns 2.82ns 10.9ns 0.00786 0 0 576 B
#5634 StartFinishSpan net472 580ns 0.501ns 1.94ns 0.0917 0 0 578 B
#5634 StartFinishScope net6.0 467ns 0.104ns 0.402ns 0.00985 0 0 696 B
#5634 StartFinishScope netcoreapp3.1 684ns 0.303ns 1.17ns 0.00933 0 0 696 B
#5634 StartFinishScope net472 916ns 0.454ns 1.76ns 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 626ns 0.209ns 0.809ns 0.00965 0 0 696 B
master RunOnMethodBegin netcoreapp3.1 944ns 0.488ns 1.82ns 0.00921 0 0 696 B
master RunOnMethodBegin net472 1.04μs 0.451ns 1.75ns 0.104 0 0 658 B
#5634 RunOnMethodBegin net6.0 590ns 0.297ns 1.15ns 0.00976 0 0 696 B
#5634 RunOnMethodBegin netcoreapp3.1 941ns 0.521ns 2.02ns 0.00938 0 0 696 B
#5634 RunOnMethodBegin net472 1.09μs 0.461ns 1.79ns 0.104 0 0 658 B

@datadog-ddstaging
Copy link

datadog-ddstaging bot commented Jun 7, 2024

Datadog Report

Branch report: tony/civisibility-uds-pipes-support
Commit report: 03fcca7
Test service: dd-trace-dotnet

✅ 0 Failed, 340419 Passed, 2131 Skipped, 22h 18m 40.44s Total Time

Comment on lines +29 to +30
// The server implementation of named pipes is flaky so have 5 attempts
var attemptsRemaining = 5;
Copy link
Member

Choose a reason for hiding this comment

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

5 attempts? Is it really that flaky?! IIRC, looking at the metrics, we normally need 1 retry, tops 😬

Copy link
Member Author

Choose a reason for hiding this comment

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

I saw a fail with 3 attempts, so I'm trying to play safe...

Copy link
Member

Choose a reason for hiding this comment

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

I still find 3 consecutive failures concerning 🙈

Copy link
Member Author

Choose a reason for hiding this comment

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

Next week I'll look deeper on why the flakiness happens, but seems like something related to our mock server, the test being flaky do parallel connections and send approx 120 spans using those. Is very stable for small payloads.

@tonyredondo tonyredondo merged commit 9048312 into master Jun 7, 2024
60 of 62 checks passed
@tonyredondo tonyredondo deleted the tony/civisibility-uds-pipes-support branch June 7, 2024 12:48
@github-actions github-actions bot added this to the vNext-v2 milestone Jun 7, 2024
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.

4 participants