Skip to main content

CommonLibrary/Telemetry/
Tier.rs

1#![allow(non_snake_case)]
2
3//! Identifier for the calling Element. Tags every emitted event so the
4//! Errors & Reliability dashboard can pivot by `$tier`.
5
6#[derive(Clone, Copy, Debug, PartialEq, Eq)]
7pub enum Tier {
8	Mountain,
9	Air,
10	Echo,
11	Rest,
12	Grove,
13	Mist,
14	SideCar,
15	Common,
16}
17
18impl Tier {
19	pub fn AsStr(&self) -> &'static str {
20		match self {
21			Self::Mountain => "mountain",
22			Self::Air => "air",
23			Self::Echo => "echo",
24			Self::Rest => "rest",
25			Self::Grove => "grove",
26			Self::Mist => "mist",
27			Self::SideCar => "sidecar",
28			Self::Common => "common",
29		}
30	}
31}