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

v7.0 - pin to MEC v7, including matching target frameworks #377

Merged
merged 2 commits into from
May 4, 2023

Conversation

nblumhardt
Copy link
Member

See also: serilog/serilog-extensions-logging#222, serilog/serilog-extensions-hosting#71, serilog/serilog-aspnetcore#325

Unfortunately we've had some maintainability problems given the wide spread of target frameworks and dependencies across the Serilog sub-projects.

My aim's to kick through some RTM versions of all of these packages, pinned to their latest Microsoft.Extensions.* counterparts, ASAP.

I know we have #343 open here (I've also held up the works there), my proposal is that we "rip the Band-Aid off" and merge this, then merge the release PR as v7.

Note that targeting v7 of the Microsoft.Extensions.* packages doesn't mean dropping earlier TFMs - the majority of the ME* packages continue supporting net462+, netstandard2.0+, and net6.0+.

On the release of .NET 8, the plan would then be to sim-ship Serilog.Extensions.* and Serilog.Settings.Configuration v8.0 versions that depend on the v8.0 dependencies (and so on, for the foreseeable future).

@Numpsy
Copy link
Member

Numpsy commented May 3, 2023

On the release of .NET 8

Would the versions built with the v7 libs roll forward to work with the v8 libs (say, if you wanted to test with ASP.Net Core 8 before it's released), or does 'pinned' actually mean '7 only' ?

@nblumhardt
Copy link
Member Author

@Numpsy thanks for checking this out! Roll-forward would work exactly as it does today. All I mean by "pinned" is that v7 of this library will have a dependency on v7 of Microsoft.Extensions.Configuration, and v8 of this library will build against v8 of M.E.C.

This probably sounds like a bigger change than it is - the main benefit is that the package's dependency graph is predictable and consistent, irrespective of the target framework and any other factors.

@nblumhardt nblumhardt merged commit 246920e into serilog:dev May 4, 2023
@@ -293,7 +293,8 @@ void ApplyEnrichment(LoggerConfiguration loggerConfiguration)
{
foreach (var enrichPropertyDirective in propertiesDirective.GetChildren())
{
loggerConfiguration.Enrich.WithProperty(enrichPropertyDirective.Key, enrichPropertyDirective.Value);
// Null is an acceptable value here; annotations on Serilog need updating.
Copy link
Contributor

Choose a reason for hiding this comment

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

@nblumhardt nblumhardt mentioned this pull request May 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants