#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 and SpanId. These are set automatically in Logger.Write() to the corresponding property values from System.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-in LogEvent.TraceId and LogEvent.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.
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Bumps Serilog from 3.0.1 to 3.1.0.
Release notes
Sourced from Serilog's releases.
Commits
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
MakeStringBuilderCapacityThreshold
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)948ea83
Added missing DynamicallyAccessedMembers in PropertyValueConverter to fix err...9b658c1
Collect and propagate current trace and span ids throughLogEvent
(#1955)db7900d
PrimitiveScalarConversionPolicy: avoiding hashset lookup for common types (#1...Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show