-
Notifications
You must be signed in to change notification settings - Fork 151
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
Capture structured logging parameter names #125
Conversation
@304NotModified If approved, then please merge #121 first (Remember to change milestone to 1.0 RC), as these two will collide. |
It could be nice if one could inject a custom format-function to the LogEventInfo (Gets LogEventInfo as input and returns string). Then it would be possible to assign This would make it easier for custom targets supported structured logging to capture the |
Created PR to improve NLog integration with Microsoft.Extensions.Logging: NLog/NLog#2244 |
Thanks for the reminder! Conflict is now here O:) |
@304NotModified Will wait with this until NLog/NLog#2244 is released (For NLog ver. 4.4 and ver. 5.0). Btw. going on vacation the next 2 weeks. |
Have a good holiday! |
(waiting on NLog 4.5 beta) |
We can continue on this one, isn't? |
Waiting for my properties dictionary to be approved. Needed to perform proper capture of message template properties
…Sent from my Samsung device
-------- Original message --------
From: Julian Verdurmen <notifications@github.com>
Date: 18/09/2017 22:57 (GMT+01:00)
To: "NLog/NLog.Extensions.Logging" <NLog.Extensions.Logging@noreply.github.com>
Cc: Rolf Kristensen <sweaty1@hotmail.com>, Author <author@noreply.github.com>
Subject: Re: [NLog/NLog.Extensions.Logging] Capture structured logging parameter names (#125)
We can continue on this one, isn't?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#125 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AK-fnAh-bsN41nhdwYQWOkDjvxdfqxeEks5sjtkygaJpZM4OuluN>.
|
@snakefoot do you think I have to delay RTM 1.0 for this PR? |
@304NotModified Still waiting for NLog/NLog#2262 :) No idea if it is needed for RTM. |
Yes, I will take more time to give better feedback.
Is this a breaking change? (functional) |
No idea. The structured logging properties provided by the Microsoft Extensions Logging are kind of secret. And since NLog doesn't support structured logging in its current state, then I guess it is okay that it is left out. But again I'm not using Microsoft Extensions Logging :) |
Please fix the conflict, thanks! |
Can see that you have done a partial update of the NLog-dependency, so now running all 3 major versions at the same time. Not the best environment to work in. But anyway have updated NetStandard2.0 to use the new MesageTemplate-logic to capture the structured-logging parameters (Kept the original method for the other major versions). |
Thanks! After 4.5 RTM I will update the dependencies Ps now 2 major versions according to semver :p |
Extracted from Microsoft FormattedLogValues. Allowing NLog to support structured logging using the Microsoft-parser-engine. Resolves #116
P.S. Funny detail discovered while digging around in the Microsoft-machine-room (Notice the static ConcurrentDictionary and limit of 1024)
https://github.com/aspnet/Logging/blob/cc503aaed0b9fb3e93345b28629e80581337d3c1/src/Microsoft.Extensions.Logging.Abstractions/Internal/FormattedLogValues.cs
P.P.S. Surprised that they are not using the StringComparer.Ordinal for the ConcurrentDictionary