Skip to content

move <Version> to new Common.props #7112

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

Closed
wants to merge 2 commits into from

Conversation

lucaspimentel
Copy link
Member

@lucaspimentel lucaspimentel commented Jun 16, 2025

🙈 DON'T LOOK, JUST EXPERIMENTING 🙈

Summary of changes

Move Version build property into a separate file...

Reason for change

...so it can be referenced from any project regardless of Directory.Build.props files in the directory hierarchy. In the future we can add other properties here as well, like <LangVersion>.

I plan to include Common.props from new projects which will intentionally ignore the default Directory.Build.props files.

Implementation details

@andrewlock recently consolidated the Version property into a single file in #7031.

This PR builds on that, but moves Version into a new tracer/src/Common.props file that can be referenced from any project or other props files. The file tracer/src/Directory.Build.props now includes the new Common.props, so the Version property remains defined as before.

Test coverage

  • If it builds, it works?
  • I also ran the UpdateVersion and VerifyChangedFilesFromVersionBump Nuke steps manually to test those.

Other details

@lucaspimentel lucaspimentel added the area:builds project files, build scripts, pipelines, versioning, releases, packages label Jun 16, 2025
@datadog-datadog-prod-us1
Copy link

datadog-datadog-prod-us1 bot commented Jun 16, 2025

Datadog Report

All test runs 1ab4b11 🔗

2 Total Test Services: 1 Failed, 1 Passed

Test Services
Service Name Failed Known Flaky New Flaky Passed Skipped Total Time Test Service View
dd-trace-dotnet 1 0 0 260944 2538 18h 1m 14.23s Link
exploration_tests 0 0 0 22085 3 2m 21.18s Link

❌ Failed Tests (1)

  • TestIastXpathInjectionRequest - Datadog.Trace.Security.IntegrationTests.Iast.AspNetCore5IastTestsFullSamplingIastEnabled - Details

    Expand for error
     Results do not match.
     Differences:
     Received: Iast.XpathInjection.AspNetCore5.IastEnabled.received.txt
     Verified: Iast.XpathInjection.AspNetCore5.IastEnabled.verified.txt
     Compare Result:
       [
         {
           TraceId: Id_1,
           SpanId: Id_2,
     -     Name: aspnet_core.request,
     ...
    

@lucaspimentel lucaspimentel force-pushed the lpimentel/common-props branch 3 times, most recently from 3de375f to 3ebda02 Compare June 16, 2025 21:52
@lucaspimentel lucaspimentel force-pushed the lpimentel/common-props branch 4 times, most recently from a78a926 to 16fb2ff Compare June 16, 2025 22:18
@lucaspimentel lucaspimentel changed the title common props move <Version> to new Common.props Jun 16, 2025
@lucaspimentel lucaspimentel force-pushed the lpimentel/common-props branch from 16fb2ff to 1ab4b11 Compare June 16, 2025 22:27
@pr-commenter
Copy link

pr-commenter bot commented Jun 16, 2025

Benchmarks

Benchmarks Report for benchmark platform 🐌

Benchmarks for #7112 compared to master:

  • 2 benchmarks are slower, with geometric mean 1.152
  • 42 benchmarks have fewer allocations
  • 5 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.ActivityBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.ActivityBenchmark.StartStopWithChild‑netcoreapp3.1 5.75 KB 5.69 KB -69 B -1.20%
Benchmarks.Trace.ActivityBenchmark.StartStopWithChild‑net6.0 5.58 KB 5.51 KB -68 B -1.22%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartStopWithChild net6.0 11.2μs 59.7ns 322ns 0 0 0 5.58 KB
master StartStopWithChild netcoreapp3.1 14.1μs 67.5ns 286ns 0 0 0 5.75 KB
master StartStopWithChild net472 22.1μs 119ns 651ns 1.03 0.411 0.103 6.09 KB
#7112 StartStopWithChild net6.0 10.4μs 57.8ns 347ns 0 0 0 5.51 KB
#7112 StartStopWithChild netcoreapp3.1 14.6μs 72.7ns 317ns 0 0 0 5.69 KB
#7112 StartStopWithChild net472 22.2μs 111ns 521ns 1.06 0.424 0.106 6.07 KB
Benchmarks.Trace.AgentWriterBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.AgentWriterBenchmark.WriteAndFlushEnrichedTraces‑net472 3.33 KB 3.31 KB -23 B -0.69%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master WriteAndFlushEnrichedTraces net6.0 927μs 26.6ns 103ns 0 0 0 2.71 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 1.04ms 404ns 1.56μs 0 0 0 2.7 KB
master WriteAndFlushEnrichedTraces net472 1.25ms 357ns 1.38μs 0 0 0 3.33 KB
#7112 WriteAndFlushEnrichedTraces net6.0 944μs 72.7ns 281ns 0 0 0 2.7 KB
#7112 WriteAndFlushEnrichedTraces netcoreapp3.1 1.01ms 207ns 804ns 0 0 0 2.7 KB
#7112 WriteAndFlushEnrichedTraces net472 1.21ms 162ns 561ns 0 0 0 3.31 KB
Benchmarks.Trace.Asm.AppSecBodyBenchmark - Same speed ✔️ More allocations ⚠️

More allocations ⚠️ in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Asm.AppSecBodyBenchmark.AllCycleSimpleBody‑net472 236.35 KB 239.64 KB 3.29 KB 1.39%
Benchmarks.Trace.Asm.AppSecBodyBenchmark.AllCycleMoreComplexBody‑net472 239.87 KB 243.15 KB 3.28 KB 1.37%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master AllCycleSimpleBody net6.0 331μs 1.76μs 8.42μs 0 0 0 197.06 KB
master AllCycleSimpleBody netcoreapp3.1 510μs 1.45μs 5.61μs 0 0 0 204.77 KB
master AllCycleSimpleBody net472 436μs 119ns 460ns 36.6 2.16 0 236.35 KB
master AllCycleMoreComplexBody net6.0 338μs 1.76μs 8.8μs 0 0 0 200.56 KB
master AllCycleMoreComplexBody netcoreapp3.1 495μs 987ns 3.56μs 0 0 0 208.18 KB
master AllCycleMoreComplexBody net472 446μs 106ns 412ns 36.6 2.16 0 239.87 KB
master ObjectExtractorSimpleBody net6.0 311ns 1.77ns 12.3ns 0 0 0 280 B
master ObjectExtractorSimpleBody netcoreapp3.1 409ns 1.93ns 8.2ns 0 0 0 272 B
master ObjectExtractorSimpleBody net472 303ns 0.175ns 0.676ns 0.0442 0 0 281 B
master ObjectExtractorMoreComplexBody net6.0 6.52μs 29.5ns 110ns 0 0 0 3.78 KB
master ObjectExtractorMoreComplexBody netcoreapp3.1 7.76μs 36.2ns 140ns 0 0 0 3.69 KB
master ObjectExtractorMoreComplexBody net472 6.66μs 0.89ns 3.33ns 0.599 0 0 3.8 KB
#7112 AllCycleSimpleBody net6.0 328μs 962ns 3.72μs 0 0 0 197.59 KB
#7112 AllCycleSimpleBody netcoreapp3.1 496μs 536ns 2.08μs 0 0 0 205.35 KB
#7112 AllCycleSimpleBody net472 445μs 118ns 457ns 37.9 2.23 0 239.64 KB
#7112 AllCycleMoreComplexBody net6.0 339μs 1.24μs 4.64μs 0 0 0 201.1 KB
#7112 AllCycleMoreComplexBody netcoreapp3.1 534μs 2.32μs 8.98μs 0 0 0 208.77 KB
#7112 AllCycleMoreComplexBody net472 456μs 296ns 1.14μs 37.9 2.23 0 243.15 KB
#7112 ObjectExtractorSimpleBody net6.0 316ns 1.52ns 6.27ns 0 0 0 280 B
#7112 ObjectExtractorSimpleBody netcoreapp3.1 396ns 2.11ns 11.5ns 0 0 0 272 B
#7112 ObjectExtractorSimpleBody net472 304ns 0.105ns 0.393ns 0.0443 0 0 281 B
#7112 ObjectExtractorMoreComplexBody net6.0 6.33μs 1.46ns 5.28ns 0 0 0 3.78 KB
#7112 ObjectExtractorMoreComplexBody netcoreapp3.1 7.63μs 35.8ns 139ns 0 0 0 3.69 KB
#7112 ObjectExtractorMoreComplexBody net472 6.85μs 5.24ns 20.3ns 0.58 0 0 3.8 KB
Benchmarks.Trace.Asm.AppSecEncoderBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Asm.AppSecEncoderBenchmark.EncodeLegacyArgs‑net6.0 2.16 KB 2.14 KB -12 B -0.56%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EncodeArgs net6.0 73.3μs 263ns 984ns 0 0 0 32.41 KB
master EncodeArgs netcoreapp3.1 95.7μs 36.2ns 130ns 0 0 0 32.4 KB
master EncodeArgs net472 107μs 17.6ns 65.8ns 4.82 0 0 32.51 KB
master EncodeLegacyArgs net6.0 143μs 122ns 472ns 0 0 0 2.16 KB
master EncodeLegacyArgs netcoreapp3.1 197μs 42.5ns 147ns 0 0 0 2.14 KB
master EncodeLegacyArgs net472 261μs 66.8ns 250ns 0 0 0 2.16 KB
#7112 EncodeArgs net6.0 72.3μs 191ns 739ns 0 0 0 32.4 KB
#7112 EncodeArgs netcoreapp3.1 95.5μs 229ns 886ns 0 0 0 32.4 KB
#7112 EncodeArgs net472 107μs 10.8ns 40.6ns 4.81 0 0 32.51 KB
#7112 EncodeLegacyArgs net6.0 145μs 50ns 187ns 0 0 0 2.14 KB
#7112 EncodeLegacyArgs netcoreapp3.1 195μs 75.9ns 294ns 0 0 0 2.15 KB
#7112 EncodeLegacyArgs net472 262μs 34.6ns 134ns 0 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 271μs 133ns 499ns 0 0 0 4.55 KB
master RunWafRealisticBenchmark netcoreapp3.1 294μs 264ns 989ns 0 0 0 4.48 KB
master RunWafRealisticBenchmark net472 307μs 38.1ns 147ns 0 0 0 4.66 KB
master RunWafRealisticBenchmarkWithAttack net6.0 181μs 80.1ns 300ns 0 0 0 2.24 KB
master RunWafRealisticBenchmarkWithAttack netcoreapp3.1 198μs 104ns 404ns 0 0 0 2.22 KB
master RunWafRealisticBenchmarkWithAttack net472 207μs 45.3ns 169ns 0 0 0 2.28 KB
#7112 RunWafRealisticBenchmark net6.0 272μs 86.9ns 325ns 0 0 0 4.55 KB
#7112 RunWafRealisticBenchmark netcoreapp3.1 293μs 120ns 432ns 0 0 0 4.48 KB
#7112 RunWafRealisticBenchmark net472 309μs 40.8ns 153ns 0 0 0 4.66 KB
#7112 RunWafRealisticBenchmarkWithAttack net6.0 182μs 31.8ns 119ns 0 0 0 2.24 KB
#7112 RunWafRealisticBenchmarkWithAttack netcoreapp3.1 196μs 148ns 555ns 0 0 0 2.22 KB
#7112 RunWafRealisticBenchmarkWithAttack net472 208μs 37.5ns 145ns 0 0 0 2.29 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 61.1μs 29ns 104ns 0 0 0 14.53 KB
master SendRequest netcoreapp3.1 69.9μs 118ns 440ns 0 0 0 17.42 KB
master SendRequest net472 0.0171ns 0.00147ns 0.00551ns 0 0 0 0 b
#7112 SendRequest net6.0 59.8μs 77.3ns 279ns 0 0 0 14.52 KB
#7112 SendRequest netcoreapp3.1 70.8μs 323ns 1.17μs 0 0 0 17.42 KB
#7112 SendRequest net472 0.0172ns 0.00228ns 0.00883ns 0 0 0 0 b
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark - Slower ⚠️ More allocations ⚠️

Slower ⚠️ in #7112

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark.WriteAndFlushEnrichedTraces‑net6.0 1.117 645,405.00 720,769.92

More allocations ⚠️ in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.CIVisibilityProtocolWriterBenchmark.WriteAndFlushEnrichedTraces‑net472 55.75 KB 56.63 KB 875 B 1.57%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master WriteAndFlushEnrichedTraces net6.0 645μs 512ns 1.98μs 0 0 0 41.73 KB
master WriteAndFlushEnrichedTraces netcoreapp3.1 631μs 1.67μs 6.67μs 0 0 0 41.89 KB
master WriteAndFlushEnrichedTraces net472 923μs 1.93μs 7.2μs 4.46 0 0 55.75 KB
#7112 WriteAndFlushEnrichedTraces net6.0 711μs 3.87μs 22.3μs 0 0 0 41.79 KB
#7112 WriteAndFlushEnrichedTraces netcoreapp3.1 696μs 4.03μs 33μs 0 0 0 41.91 KB
#7112 WriteAndFlushEnrichedTraces net472 832μs 3.56μs 13.3μs 8.33 0 0 56.63 KB
Benchmarks.Trace.DbCommandBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.DbCommandBenchmark.ExecuteNonQuery‑net6.0 1.03 KB 1.02 KB -8 B -0.78%
Benchmarks.Trace.DbCommandBenchmark.ExecuteNonQuery‑netcoreapp3.1 1.02 KB 1.02 KB -8 B -0.78%
Benchmarks.Trace.DbCommandBenchmark.ExecuteNonQuery‑net472 995 B 987 B -8 B -0.80%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master ExecuteNonQuery net6.0 1.99μs 10.2ns 46.8ns 0 0 0 1.03 KB
master ExecuteNonQuery netcoreapp3.1 2.53μs 3.43ns 13.3ns 0 0 0 1.02 KB
master ExecuteNonQuery net472 2.7μs 2.41ns 9.34ns 0.147 0.0134 0 995 B
#7112 ExecuteNonQuery net6.0 1.93μs 8.22ns 31.8ns 0 0 0 1.02 KB
#7112 ExecuteNonQuery netcoreapp3.1 2.59μs 10.5ns 40.7ns 0 0 0 1.02 KB
#7112 ExecuteNonQuery net472 2.83μs 5.28ns 20.4ns 0.154 0.014 0 987 B
Benchmarks.Trace.ElasticsearchBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.ElasticsearchBenchmark.CallElasticsearchAsync‑net472 1.11 KB 1.1 KB -8 B -0.72%
Benchmarks.Trace.ElasticsearchBenchmark.CallElasticsearchAsync‑netcoreapp3.1 1.09 KB 1.08 KB -8 B -0.74%
Benchmarks.Trace.ElasticsearchBenchmark.CallElasticsearch‑net472 1.05 KB 1.04 KB -8 B -0.76%
Benchmarks.Trace.ElasticsearchBenchmark.CallElasticsearch‑net6.0 1.04 KB 1.03 KB -8 B -0.77%
Benchmarks.Trace.ElasticsearchBenchmark.CallElasticsearch‑netcoreapp3.1 1.04 KB 1.03 KB -8 B -0.77%
Benchmarks.Trace.ElasticsearchBenchmark.CallElasticsearchAsync‑net6.0 1.02 KB 1.01 KB -8 B -0.79%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master CallElasticsearch net6.0 1.83μs 5.85ns 22.7ns 0 0 0 1.04 KB
master CallElasticsearch netcoreapp3.1 2.3μs 11.8ns 56.6ns 0 0 0 1.04 KB
master CallElasticsearch net472 3.55μs 3.05ns 11.8ns 0.159 0 0 1.05 KB
master CallElasticsearchAsync net6.0 1.81μs 3.89ns 14.5ns 0 0 0 1.02 KB
master CallElasticsearchAsync netcoreapp3.1 2.35μs 7.26ns 28.1ns 0 0 0 1.09 KB
master CallElasticsearchAsync net472 3.84μs 3.19ns 12.4ns 0.169 0 0 1.11 KB
#7112 CallElasticsearch net6.0 1.8μs 7.51ns 29.1ns 0 0 0 1.03 KB
#7112 CallElasticsearch netcoreapp3.1 2.25μs 8.71ns 33.8ns 0 0 0 1.03 KB
#7112 CallElasticsearch net472 3.69μs 3.88ns 15ns 0.165 0 0 1.04 KB
#7112 CallElasticsearchAsync net6.0 1.87μs 6.62ns 25.7ns 0 0 0 1.01 KB
#7112 CallElasticsearchAsync netcoreapp3.1 2.39μs 11.7ns 46.7ns 0 0 0 1.08 KB
#7112 CallElasticsearchAsync net472 3.83μs 3.15ns 12.2ns 0.171 0 0 1.1 KB
Benchmarks.Trace.GraphQLBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.GraphQLBenchmark.ExecuteAsync‑net6.0 960 B 952 B -8 B -0.83%
Benchmarks.Trace.GraphQLBenchmark.ExecuteAsync‑netcoreapp3.1 960 B 952 B -8 B -0.83%
Benchmarks.Trace.GraphQLBenchmark.ExecuteAsync‑net472 923 B 915 B -8 B -0.87%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master ExecuteAsync net6.0 1.78μs 9.27ns 43.5ns 0 0 0 960 B
master ExecuteAsync netcoreapp3.1 2.29μs 7.45ns 25.8ns 0 0 0 960 B
master ExecuteAsync net472 2.58μs 1.78ns 6.88ns 0.143 0 0 923 B
#7112 ExecuteAsync net6.0 1.9μs 3.97ns 15.4ns 0 0 0 952 B
#7112 ExecuteAsync netcoreapp3.1 2.43μs 8.59ns 32.1ns 0 0 0 952 B
#7112 ExecuteAsync net472 2.51μs 0.827ns 2.98ns 0.139 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 7.1μs 10.4ns 39ns 0 0 0 2.37 KB
master SendAsync netcoreapp3.1 8.69μs 14.1ns 54.6ns 0 0 0 2.9 KB
master SendAsync net472 12.5μs 10.3ns 38.5ns 0.498 0 0 3.19 KB
#7112 SendAsync net6.0 6.99μs 7.14ns 27.7ns 0 0 0 2.36 KB
#7112 SendAsync netcoreapp3.1 8.42μs 21ns 81.5ns 0 0 0 2.9 KB
#7112 SendAsync net472 12.4μs 11.7ns 45.2ns 0.496 0 0 3.18 KB
Benchmarks.Trace.Iast.StringAspectsBenchmark - Slower ⚠️ More allocations ⚠️

Slower ⚠️ in #7112

Benchmark diff/base Base Median (ns) Diff Median (ns) Modality
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑netcoreapp3.1 1.189 413,700.00 491,900.00

More allocations ⚠️ in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net6.0 259.96 KB 278.35 KB 18.39 KB 7.07%
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatBenchmark‑netcoreapp3.1 42.64 KB 43.64 KB 1 KB 2.35%

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑net472 286.72 KB 278.53 KB -8.19 KB -2.86%
Benchmarks.Trace.Iast.StringAspectsBenchmark.StringConcatAspectBenchmark‑netcoreapp3.1 274.93 KB 249.39 KB -25.54 KB -9.29%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StringConcatBenchmark net6.0 44.6μs 212ns 1.6μs 0 0 0 43.83 KB
master StringConcatBenchmark netcoreapp3.1 47.2μs 224ns 838ns 0 0 0 42.64 KB
master StringConcatBenchmark net472 56.8μs 259ns 968ns 0 0 0 57.34 KB
master StringConcatAspectBenchmark net6.0 458μs 1.08μs 3.89μs 0 0 0 259.96 KB
master StringConcatAspectBenchmark netcoreapp3.1 447μs 6.44μs 63.7μs 0 0 0 274.93 KB
master StringConcatAspectBenchmark net472 410μs 2.07μs 9.27μs 0 0 0 286.72 KB
#7112 StringConcatBenchmark net6.0 45.3μs 254ns 1.52μs 0 0 0 43.78 KB
#7112 StringConcatBenchmark netcoreapp3.1 49.5μs 283ns 2.44μs 0 0 0 43.64 KB
#7112 StringConcatBenchmark net472 56.7μs 261ns 1.04μs 0 0 0 57.34 KB
#7112 StringConcatAspectBenchmark net6.0 473μs 930ns 3.22μs 0 0 0 278.35 KB
#7112 StringConcatAspectBenchmark netcoreapp3.1 492μs 1.11μs 3.85μs 0 0 0 249.39 KB
#7112 StringConcatAspectBenchmark net472 411μs 2.23μs 12.6μs 0 0 0 278.53 KB
Benchmarks.Trace.ILoggerBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.ILoggerBenchmark.EnrichedLog‑net6.0 1.76 KB 1.7 KB -56 B -3.18%
Benchmarks.Trace.ILoggerBenchmark.EnrichedLog‑netcoreapp3.1 1.76 KB 1.7 KB -56 B -3.18%
Benchmarks.Trace.ILoggerBenchmark.EnrichedLog‑net472 1.69 KB 1.64 KB -56 B -3.31%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 2.63μs 2.6ns 10.1ns 0 0 0 1.76 KB
master EnrichedLog netcoreapp3.1 3.44μs 4.38ns 17ns 0 0 0 1.76 KB
master EnrichedLog net472 4.05μs 4.83ns 18.7ns 0.265 0 0 1.69 KB
#7112 EnrichedLog net6.0 2.68μs 11.9ns 46.1ns 0 0 0 1.7 KB
#7112 EnrichedLog netcoreapp3.1 3.48μs 15.8ns 63.3ns 0 0 0 1.7 KB
#7112 EnrichedLog net472 3.87μs 4.9ns 19ns 0.25 0 0 1.64 KB
Benchmarks.Trace.Log4netBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.Log4netBenchmark.EnrichedLog‑net6.0 4.37 KB 4.31 KB -56 B -1.28%
Benchmarks.Trace.Log4netBenchmark.EnrichedLog‑net472 4.57 KB 4.51 KB -60 B -1.31%
Benchmarks.Trace.Log4netBenchmark.EnrichedLog‑netcoreapp3.1 4.37 KB 4.31 KB -58 B -1.33%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 123μs 145ns 563ns 0 0 0 4.37 KB
master EnrichedLog netcoreapp3.1 126μs 330ns 1.24μs 0 0 0 4.37 KB
master EnrichedLog net472 167μs 161ns 603ns 0 0 0 4.57 KB
#7112 EnrichedLog net6.0 122μs 70.1ns 253ns 0 0 0 4.31 KB
#7112 EnrichedLog netcoreapp3.1 126μs 157ns 610ns 0 0 0 4.31 KB
#7112 EnrichedLog net472 166μs 41.8ns 162ns 0 0 0 4.51 KB
Benchmarks.Trace.NLogBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.NLogBenchmark.EnrichedLog‑net6.0 2.32 KB 2.26 KB -56 B -2.41%
Benchmarks.Trace.NLogBenchmark.EnrichedLog‑netcoreapp3.1 2.32 KB 2.26 KB -56 B -2.41%
Benchmarks.Trace.NLogBenchmark.EnrichedLog‑net472 2.14 KB 2.08 KB -56 B -2.62%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 4.94μs 19.3ns 74.6ns 0 0 0 2.32 KB
master EnrichedLog netcoreapp3.1 6.77μs 22.2ns 79.9ns 0 0 0 2.32 KB
master EnrichedLog net472 7.45μs 8.04ns 31.1ns 0.335 0 0 2.14 KB
#7112 EnrichedLog net6.0 4.95μs 26ns 133ns 0 0 0 2.26 KB
#7112 EnrichedLog netcoreapp3.1 6.94μs 18.4ns 71.3ns 0 0 0 2.26 KB
#7112 EnrichedLog net472 7.55μs 5.8ns 22.5ns 0.301 0 0 2.08 KB
Benchmarks.Trace.RedisBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.RedisBenchmark.SendReceive‑net472 1.21 KB 1.2 KB -8 B -0.66%
Benchmarks.Trace.RedisBenchmark.SendReceive‑net6.0 1.21 KB 1.2 KB -8 B -0.66%
Benchmarks.Trace.RedisBenchmark.SendReceive‑netcoreapp3.1 1.21 KB 1.2 KB -8 B -0.66%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master SendReceive net6.0 2.04μs 10.5ns 49.4ns 0 0 0 1.21 KB
master SendReceive netcoreapp3.1 2.53μs 11.8ns 47.4ns 0 0 0 1.21 KB
master SendReceive net472 3.28μs 2.71ns 10.5ns 0.178 0 0 1.21 KB
#7112 SendReceive net6.0 2.06μs 10ns 40.2ns 0 0 0 1.2 KB
#7112 SendReceive netcoreapp3.1 2.58μs 1.57ns 6.09ns 0 0 0 1.2 KB
#7112 SendReceive net472 3.1μs 5.85ns 22.7ns 0.186 0 0 1.2 KB
Benchmarks.Trace.SerilogBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.SerilogBenchmark.EnrichedLog‑net472 2.08 KB 2.03 KB -56 B -2.69%
Benchmarks.Trace.SerilogBenchmark.EnrichedLog‑netcoreapp3.1 1.69 KB 1.63 KB -56 B -3.32%
Benchmarks.Trace.SerilogBenchmark.EnrichedLog‑net6.0 1.64 KB 1.58 KB -56 B -3.41%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master EnrichedLog net6.0 4.18μs 0.92ns 3.44ns 0 0 0 1.64 KB
master EnrichedLog netcoreapp3.1 5.64μs 23ns 89.3ns 0 0 0 1.69 KB
master EnrichedLog net472 6.67μs 7.28ns 27.3ns 0.298 0 0 2.08 KB
#7112 EnrichedLog net6.0 4.18μs 8.36ns 31.3ns 0 0 0 1.58 KB
#7112 EnrichedLog netcoreapp3.1 5.58μs 19ns 73.4ns 0 0 0 1.63 KB
#7112 EnrichedLog net472 6.63μs 4.83ns 18.7ns 0.295 0 0 2.03 KB
Benchmarks.Trace.SpanBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.SpanBenchmark.StartFinishScope‑net6.0 704 B 696 B -8 B -1.14%
Benchmarks.Trace.SpanBenchmark.StartFinishScope‑netcoreapp3.1 704 B 696 B -8 B -1.14%
Benchmarks.Trace.SpanBenchmark.StartFinishScope‑net472 666 B 658 B -8 B -1.20%
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑net472 586 B 578 B -8 B -1.37%
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑net6.0 584 B 576 B -8 B -1.37%
Benchmarks.Trace.SpanBenchmark.StartFinishSpan‑netcoreapp3.1 584 B 576 B -8 B -1.37%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master StartFinishSpan net6.0 751ns 3.97ns 22.4ns 0 0 0 584 B
master StartFinishSpan netcoreapp3.1 953ns 4.42ns 17.7ns 0 0 0 584 B
master StartFinishSpan net472 914ns 0.809ns 3.13ns 0.0912 0 0 586 B
master StartFinishScope net6.0 918ns 0.479ns 1.73ns 0 0 0 704 B
master StartFinishScope netcoreapp3.1 1.15μs 6.24ns 34.2ns 0 0 0 704 B
master StartFinishScope net472 1.09μs 0.174ns 0.652ns 0.104 0 0 666 B
#7112 StartFinishSpan net6.0 763ns 0.241ns 0.87ns 0 0 0 576 B
#7112 StartFinishSpan netcoreapp3.1 953ns 2.1ns 8.14ns 0 0 0 576 B
#7112 StartFinishSpan net472 907ns 0.364ns 1.41ns 0.0913 0 0 578 B
#7112 StartFinishScope net6.0 879ns 4.91ns 32.2ns 0 0 0 696 B
#7112 StartFinishScope netcoreapp3.1 1.17μs 1.54ns 5.95ns 0 0 0 696 B
#7112 StartFinishScope net472 1.12μs 0.535ns 2.07ns 0.102 0 0 658 B
Benchmarks.Trace.TraceAnnotationsBenchmark - Same speed ✔️ Fewer allocations 🎉

Fewer allocations 🎉 in #7112

Benchmark Base Allocated Diff Allocated Change Change %
Benchmarks.Trace.TraceAnnotationsBenchmark.RunOnMethodBegin‑net6.0 704 B 696 B -8 B -1.14%
Benchmarks.Trace.TraceAnnotationsBenchmark.RunOnMethodBegin‑netcoreapp3.1 704 B 696 B -8 B -1.14%
Benchmarks.Trace.TraceAnnotationsBenchmark.RunOnMethodBegin‑net472 666 B 658 B -8 B -1.20%

Raw results

Branch Method Toolchain Mean StdError StdDev Gen 0 Gen 1 Gen 2 Allocated
master RunOnMethodBegin net6.0 1.02μs 5.36ns 26.8ns 0 0 0 704 B
master RunOnMethodBegin netcoreapp3.1 1.38μs 2.28ns 8.82ns 0 0 0 704 B
master RunOnMethodBegin net472 1.36μs 0.141ns 0.544ns 0.102 0 0 666 B
#7112 RunOnMethodBegin net6.0 1.02μs 5.28ns 24.2ns 0 0 0 696 B
#7112 RunOnMethodBegin netcoreapp3.1 1.39μs 6.67ns 25.8ns 0 0 0 696 B
#7112 RunOnMethodBegin net472 1.38μs 1.72ns 6.65ns 0.103 0 0 658 B

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.

Probably a silly question, but why 🤔 You can already reference Directory.Build.props outside of directory hierarchy, and we can just override any new values you don't need? 🤷‍♂️ I'm not opposed in general, just seems like it's going be Yet Another File without reducing complexity?

@lucaspimentel
Copy link
Member Author

Probably a silly question, but why

Not a silly question! I was just experimenting because the default Directory.Build.props have lots of stuff I wasn't interested in. Pretty much the only thing I wanted to keep was <Version> since you consolidated it recently and that was nice.

Anyway, that was yesterday, and earlier today we discussed this on zoom, so I'm closing this. Thanks!

@lucaspimentel
Copy link
Member Author

(Although I do think we can make some of those things easier to opt-in/opt-out rather than applying blindly everywhere.)

@lucaspimentel lucaspimentel deleted the lpimentel/common-props branch June 17, 2025 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:builds project files, build scripts, pipelines, versioning, releases, packages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants