Sourced from Serilog's releases.
v3.1.1
- #1977 - don't stack overflow when disposing
ReusableStringWriter
with large renderings (@nblumhardt
)This is a bugfix for release 3.1.0.
v3.1.0
- #1935 - remove
CHANGES.md
(@sungam3r
)- #1936, #1922 -
README.md
updates (@nblumhardt
)- #1942 - remove redundant
GetTypeInfo()
calls (@SimonCropp
)- #1947 - message template caching performance improvements (
@epeshk
)- #1948 - reduce allocations in
Logger.Write()
(@epeshk
)- #1955 breaking - collect and propagate
Activity.Current.TraceId
andSpanId
automatically inLogger.Write()
(@nblumhardt
)- #1964 - don't cache reusable string writers with large buffer sizes (
@Jakimar
)- #1969 -
README.md
updates (@bartelink
)- #1971 - drop test coverage for unsupported .NET Core versions (
@bartelink
)Built-in trace and span id support
This release adds two new first-class properties to
LogEvent
:TraceId
andSpanId
. These are set automatically inLogger.Write()
to the corresponding property values fromSystem.Diagnostics.Activity.Current
.The major benefit of this change is that sinks, once updated, can reliably propagate trace and span ids through to back-ends that support them (in much the same way that first-class timestamps, messages, levels, and exceptions are used today).
The sinks maintained under
serilog/serilog
, along with formatting helpers such as Serilog.Formatting.Compact and Serilog.Expressions, are already compatible with this change or have pending releases that add compatibility.Breaking change
Trace and span id collection includes support for
{TraceId}
and{SpanId}
placeholders in output templates (commonly used when formatting text log files). Where previously these names resolved to user-defined properties, they now resolve to the built-inLogEvent.TraceId
andLogEvent.SpanId
values, respectively.Impact is expected to be low, because the trace and span id values in any user-added properties are likely to be identical to the built-in ones.
999d686
Merge pull request #1978
from serilog/dev16739f0
Don't stack overflow when disposing ReusableStringWriter
(#1977)ca4efda
Dev version bump [skip ci]765a046
Merge pull request #1975
from serilog/deve37837e
chore(docs): Markdown housekeeping (#1969)a493ffd
chore: Drop test coverage for out of support .NET Core vers (#1971)e059e9f
Make StringBuilderCapacityThreshold
the even power of two
that was intended8d0e2ed
ReusableStringWriter: Dispose instance with too big buffer (#1964)88f76a8
By reference string comparison in template cache (#1947)d6e80e6
Removed temporary array allocations for properties (#1948)