Closed daniel-white closed 1 year ago
IMO this is getting too complex for an attribute based approach, so should be out of the scope of this project. @nblumhardt @sungam3r thoughts?
Seems like a good candidate for a plug-in; this library supports IPropertyDestructuringAttribute
and ITypeDestructuringAttribute
, so should be possible to publish separately outside this project, and plug it in when desired. HTH!
Sorry for the late reply. I had a long break from OSS. @SimonCropp I agree that in may be too complex but I don't know without some API sketch. @daniel-white Could you please describe in more details your proposal.
Closed due to inactivity.
Json.NET has
[ExtensionData]
(see: https://www.newtonsoft.com/json/help/html/DeserializeExtensionData.htm). This is sometime used to allow for dynamic property population on deserialization.By default, Serilog will capture all the pairs in a
Dictionary<TKey, TValue>
. I'm proposing that there is a way to do a whitelist or blacklist with configuring the value masking for each key or using a default if not configured. I'm thinking it would work similarly to xUnit's theory class data.Another option is to transform the dictionary into a list of its keys and logging that.