Skip to content

Commit a2ccb98

Browse files
authored
subscriber: fix outdated formatter docs (#1893)
This fixes outdated statements in the docs for the `Full` and `Compact` logging formats. Closes #1880. Signed-off-by: Eliza Weisman <[email protected]>
1 parent cdac451 commit a2ccb98

File tree

1 file changed

+7
-3
lines changed
  • tracing-subscriber/src/fmt/format

1 file changed

+7
-3
lines changed

tracing-subscriber/src/fmt/format/mod.rs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -301,13 +301,17 @@ pub struct FieldFnVisitor<'a, F> {
301301
}
302302
/// Marker for `Format` that indicates that the compact log format should be used.
303303
///
304-
/// The compact format only includes the fields from the most recently entered span.
304+
/// The compact format includes fields from all currently entered spans, after
305+
/// the event's fields. Span fields are not grouped by span, and span names are
306+
/// not shown. In addition, a more compact representation of each event's
307+
/// [`Level`](tracing::Level) is used.
305308
#[derive(Default, Debug, Copy, Clone, Eq, PartialEq)]
306309
pub struct Compact;
307310

308-
/// Marker for `Format` that indicates that the verbose log format should be used.
311+
/// Marker for `Format` that indicates that the default log format should be used.
309312
///
310-
/// The full format includes fields from all entered spans.
313+
/// This format shows the span context before printing event data. Spans are
314+
/// displayed including their names and fields.
311315
#[derive(Default, Debug, Copy, Clone, Eq, PartialEq)]
312316
pub struct Full;
313317

0 commit comments

Comments
 (0)