feat(csharp/Benchmarks): Add .NET Framework 4.7.2 support with TLS co…#3682
Merged
CurtHagenlocher merged 3 commits intoNov 4, 2025
Merged
Conversation
…nfiguration This commit enhances the CloudFetch benchmark suite to support testing on .NET Framework 4.7.2, which is the runtime used by Power BI. Changes: - Add net472 target framework to Benchmarks.csproj - Make Tests project reference conditional (net8.0 only, since Tests doesn't support net472) - Enable TLS 1.2/1.3 in CloudFetchBenchmarkRunner for .NET Framework - Enable TLS 1.2/1.3 in benchmark GlobalSetup for spawned processes These changes are necessary because .NET Framework 4.7.2 doesn't enable modern TLS protocols by default, which are required for Databricks HTTPS connections. This allows accurate performance testing on the Power BI runtime environment (net472 with DefaultArrayPool). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
3 tasks
CurtHagenlocher
requested changes
Nov 4, 2025
Contributor
CurtHagenlocher
left a comment
There was a problem hiding this comment.
Thanks! Instead of conditionally compiling for .NET 8.0, can we change the target frameworks so they only target .NET 4.7.2 when built on Windows?
Address review feedback: Instead of conditionally including the Tests project reference based on TargetFramework, use the same pattern as the Tests project itself with conditional TargetFrameworks based on the IsWindows property. This ensures net472 is only targeted on Windows platforms where it's supported, making the Tests project reference always compatible. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
| * limitations under the License. | ||
| */ | ||
|
|
||
| #if NET8_0 |
Contributor
There was a problem hiding this comment.
Do we still need the #ifs in this file?
Address review feedback: Remove #if NET8_0 preprocessor directives since the Tests project is now available for both net8.0 and net472 on Windows due to the conditional TargetFrameworks approach. The Apache.Arrow.Adbc.Tests project reference is now always available for all target frameworks that the Benchmarks project builds for. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
CurtHagenlocher
approved these changes
Nov 4, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit enhances the CloudFetch benchmark suite to support testing on .NET Framework 4.7.2, which is the runtime used by Power BI. There are some notable difference in .NET472 vs .NET8.0, one of them is /K4os.Compression.LZ4 use the DefaultArrayPool in .NET472 which has a 1 MB upper limit for array size, where .NET8.0 use the SharedArrayPool which almost have no size limit.
Changes:
These changes are necessary because .NET Framework 4.7.2 doesn't enable modern TLS protocols by default, which are required for Databricks HTTPS connections. This allows accurate performance testing on the Power BI runtime environment (net472 with DefaultArrayPool).
Command:
dotnet run -c Release --project Benchmarks/Benchmarks.csproj --framework net472 CloudFetchBenchmarkRunnerSample output:
🤖 Generated with Claude Code