🛈 Note: This is pre-release documentation for the upcoming tracing 0.2.0 ecosystem.

For the release documentation, please see docs.rs, instead.

tracing_journald

Enum Priority

Source
#[repr(u8)]
pub enum Priority { Emergency = 48, Alert = 49, Critical = 50, Error = 51, Warning = 52, Notice = 53, Informational = 54, Debug = 55, }
Expand description

A priority (called “severity code” by syslog) is used to mark the importance of a message.

Descriptions and examples are taken from the Arch Linux wiki. Priorities are also documented in the section 6.2.1 of the Syslog protocol RFC.

Variants§

§

Emergency = 48

System is unusable.

Examples:

  • severe Kernel BUG
  • systemd dumped core

This level should not be used by applications.

§

Alert = 49

Should be corrected immediately.

Examples:

  • Vital subsystem goes out of work, data loss:
  • kernel: BUG: unable to handle kernel paging request at ffffc90403238ffc
§

Critical = 50

Critical conditions

Examples:

  • Crashe, coredumps
  • systemd-coredump[25319]: Process 25310 (plugin-container) of user 1000 dumped core
§

Error = 51

Error conditions

Examples:

  • Not severe error reported
  • kernel: usb 1-3: 3:1: cannot get freq at ep 0x84, systemd[1]: Failed unmounting /var
  • libvirtd[1720]: internal error: Failed to initialize a valid firewall backend
§

Warning = 52

May indicate that an error will occur if action is not taken.

Examples:

  • a non-root file system has only 1GB free
  • org.freedesktop. Notifications[1860]: (process:5999): Gtk-WARNING **: Locale not supported by C library. Using the fallback 'C' locale
§

Notice = 53

Events that are unusual, but not error conditions.

Examples:

  • systemd[1]: var.mount: Directory /var to mount over is not empty, mounting anyway
  • gcr-prompter[4997]: Gtk: GtkDialog mapped without a transient parent. This is discouraged
§

Informational = 54

Normal operational messages that require no action.

Example: lvm[585]: 7 logical volume(s) in volume group "archvg" now active

§

Debug = 55

Information useful to developers for debugging the application.

Example: kdeinit5[1900]: powerdevil: Scheduling inhibition from ":1.14" "firefox" with cookie 13 and reason "screen"

Trait Implementations§

Source§

impl Clone for Priority

Source§

fn clone(&self) -> Priority

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Priority

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Hash for Priority

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl PartialEq for Priority

Source§

fn eq(&self, other: &Priority) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Copy for Priority

Source§

impl Eq for Priority

Source§

impl StructuralPartialEq for Priority

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit #126799)
Performs copy-assignment from self to dst. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithCollector for T

Source§

fn with_collector<C>(self, collector: C) -> WithDispatch<Self>
where C: Into<Dispatch>,

Attaches the provided collector to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_collector(self) -> WithDispatch<Self>

Attaches the current default collector to this type, returning a WithDispatch wrapper. Read more