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

Update projects for .NET 8.0 and 9.0 support #648

Merged
merged 9 commits into from
Jan 30, 2025

Conversation

falvarez1
Copy link
Contributor

@falvarez1 falvarez1 commented Jan 29, 2025

Description

This PR removes .NET 6.0 support (as it has reached end-of-life) and adds .NET 9.0 support. Package references have been updated to their latest versions, which resolves all reported security vulnerabilities.

Issues Addressed

Changes

Project Updates

  • RulesEngine.csproj: Updated target frameworks to .NET 9.0 and modernized package references
  • RulesEngine.UnitTest.csproj: Added .NET 8.0 and 9.0 targets; upgraded testing libraries
  • global.json: Updated SDK version to 9.0.0

Demo Applications

  • DemoApp.csproj: Added .NET 8.0 and 9.0 targets while maintaining project references
  • DemoApp.EFDataExample.csproj: Updated to .NET 8.0/9.0 with EF Core 9.0.1
  • DemoApp fixed by adding support for comparing JsonElement with null

Benchmark Project

  • RulesEngineBenchmark.csproj: Added .NET 8.0/9.0 targets; upgraded BenchmarkDotNet to 0.14.0
  • Program.cs: Added framework-specific benchmark attributes

Testing

  • Unit tests passing on .NET 6.0, 8.0 and 9.0
  • Benchmarks executed successfully across both frameworks

- Added BenchmarkDotNet attributes in Program.cs for .NET 8.0 and 9.0.
- Updated RulesEngineBenchmark.csproj to target .NET 8.0 and 9.0; upgraded BenchmarkDotNet to 0.14.0.
- Modified DemoApp.EFDataExample.csproj to target .NET 8.0 and 9.0; upgraded EF Core packages to 9.0.1.
- Changed DemoApp.csproj to target .NET 8.0 and 9.0, preserving project references and workflow files.
- Updated global.json to specify SDK version 9.0.0.
- Modified RulesEngine.csproj to target .NET 9.0 and updated package references, including System.Text.Json.
- Updated RulesEngine.UnitTest.csproj to target .NET 8.0 and 9.0; upgraded testing libraries and System.Text.Json.
@falvarez1
Copy link
Contributor Author

Hi @pbhal

Can you please review the PR, it fixes many of the outstanding issues and vulnerabilities.

@YogeshPraj
Copy link
Contributor

@falvarez1 Can we keep .Net 6 also?

@falvarez1
Copy link
Contributor Author

@falvarez1 Can we keep .Net 6 also?

Sure, I can keep .net 6 support, but why do this when Microsoft doesn't support it anymore?

@falvarez1
Copy link
Contributor Author

@YogeshPraj actually if I re-introduce .Net 6 then that brings in the vulnerabilities for packages like System.Text.Json. I would have to downgrade the version to 6.0.11

reference:
GHSA-8g4q-xg66-9fp4
GHSA-hh2w-p6rv-4g7w

How would you like for me to continue?

@falvarez1
Copy link
Contributor Author

@YogeshPraj

Added .Net6.0 back c85cab6

@pbhal
Copy link
Contributor

pbhal commented Jan 30, 2025

@falvarez1 - Thank you for the PR, it looks good to me.

@pbhal pbhal self-requested a review January 30, 2025 04:34
@pbhal pbhal merged commit 5dd85b4 into microsoft:main Jan 30, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment