Does this sink support expression templates?
cryo75 opened this issue · 1 comments
cryo75 commented
In my rolling file sink I have:
"Formatter": {
"Type": "Serilog.Templates.ExpressionTemplate, Serilog.Expressions",
"Template": "{@t:yyyy-MM-dd HH:mm:ss.fff zzz} [{@l:u3}]{#if SourceContext is not null} ({Substring(SourceContext, LastIndexOf(SourceContext, '.') + 1)}){#end} {@m:lj}\n{@x}"
},
Can the above also be used with the email sink out of the box?
nblumhardt commented
Could be some problems for overload resolution - try the 3.0.0-dev versions of the package, and pass the ExpressionTemplate
in code I think. The overloads of WriteTo.Email
need some work.