-
Notifications
You must be signed in to change notification settings - Fork 104
Remove closure allocation in SerilogLoggerProvider. #277
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
Conversation
nblumhardt
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great, thanks for jumping through all the hoops required for this :-)
Since the logic is now spread between the method and the ScopeCollector helper type, what do you think of making it pull a little more weight, by making the ScopeItems property private, and shifting some more logic into it?
I've sketched a bit of what this might look like, but I didn't give much thought to whether Reverse() could be given a more intent-driven name, or whether the Complete() call might be more like bool TryComplete(out ...), etc.
src/Serilog.Extensions.Logging/Extensions/Logging/SerilogLoggerProvider.cs
Outdated
Show resolved
Hide resolved
src/Serilog.Extensions.Logging/Extensions/Logging/SerilogLoggerProvider.cs
Outdated
Show resolved
Hide resolved
src/Serilog.Extensions.Logging/Extensions/Logging/SerilogLoggerProvider.cs
Outdated
Show resolved
Hide resolved
|
Thanks @AndreReise 👍 |
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [Serilog.Extensions.Logging](https://github.com/serilog/serilog-extensions-logging) | nuget | major | `9.0.2` -> `10.0.0` | --- ### Release Notes <details> <summary>serilog/serilog-extensions-logging (Serilog.Extensions.Logging)</summary> ### [`v10.0.0`](https://github.com/serilog/serilog-extensions-logging/releases/tag/v10.0.0) #### What's Changed - Remove closure allocation in SerilogLoggerProvider. by [@​AndreReise](https://github.com/AndreReise) in serilog/serilog-extensions-logging#277 - Add a `net10.0` target by [@​nblumhardt](https://github.com/nblumhardt) in serilog/serilog-extensions-logging#282 **Full Changelog**: serilog/serilog-extensions-logging@v9.0.2...v10.0.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or PR is renamed to start with "rebase!". 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://github.com/renovatebot/renovate/discussions) if that's undesired. --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
Addresses #276 issue
BEFORE
AFTER