Enum relay_cabi::DataCategory

source ·
#[repr(i8)]
pub enum DataCategory {
Show 22 variants Default = 0, Error = 1, Transaction = 2, Security = 3, Attachment = 4, Session = 5, Profile = 6, Replay = 7, TransactionProcessed = 8, TransactionIndexed = 9, Monitor = 10, ProfileIndexed = 11, Span = 12, MonitorSeat = 13, UserReportV2 = 14, MetricBucket = 15, SpanIndexed = 16, ProfileDuration = 17, ProfileChunk = 18, MetricSecond = 19, ReplayVideo = 20, Unknown = -1,
}
Expand description

Classifies the type of data that is being ingested.

Variants§

§

Default = 0

Reserved and unused.

§

Error = 1

Error events and Events with an event_type not explicitly listed below.

§

Transaction = 2

Transaction events.

§

Security = 3

Events with an event type of csp, hpkp, expectct and expectstaple.

§

Attachment = 4

An attachment. Quantity is the size of the attachment in bytes.

§

Session = 5

Session updates. Quantity is the number of updates in the batch.

§

Profile = 6

Profile

This is the category for processed profiles (all profiles, whether or not we store them).

§

Replay = 7

Session Replays

§

TransactionProcessed = 8

DEPRECATED: A transaction for which metrics were extracted.

This category is now obsolete because the Transaction variant will represent processed transactions from now on.

§

TransactionIndexed = 9

Indexed transaction events.

This is the category for transaction payloads that were accepted and stored in full. In contrast, transaction only guarantees that metrics have been accepted for the transaction.

§

Monitor = 10

Monitor check-ins.

§

ProfileIndexed = 11

Indexed Profile

This is the category for indexed profiles that will be stored later.

§

Span = 12

Span

This is the category for spans from which we extracted metrics from.

§

MonitorSeat = 13

Monitor Seat

Represents a monitor job that has scheduled monitor checkins. The seats are not ingested but we define it here to prevent clashing values since this data category enumeration is also used outside of Relay via the Python package.

§

UserReportV2 = 14

User Feedback

Represents a User Feedback processed. Currently standardized on name UserReportV2 to avoid clashing with the old UserReport. TODO(jferg): Rename this to UserFeedback once old UserReport is deprecated.

§

MetricBucket = 15

Metric buckets.

§

SpanIndexed = 16

SpanIndexed

This is the category for spans we store in full.

§

ProfileDuration = 17

ProfileDuration

This data category is used to count the number of milliseconds we have per indexed profile chunk. We will then bill per second.

§

ProfileChunk = 18

ProfileChunk

This is a count of profile chunks received. It will not be used for billing but will be useful for customers to track what’s being dropped.

§

MetricSecond = 19

MetricSecond

Reserved by billing to summarize the bucketed product of metric volume and metric cardinality. Defined here so as not to clash with future categories.

§

ReplayVideo = 20

Replay Video

This is the data category for Session Replays produced via a video recording.

§

Unknown = -1

Any other data category not known by this Relay.

Implementations§

source§

impl DataCategory

source

pub fn from_name(string: &str) -> DataCategory

Returns the data category corresponding to the given name.

source

pub fn name(self) -> &'static str

Returns the canonical name of this data category.

source

pub fn is_error(self) -> bool

Returns true if the DataCategory refers to an error (i.e an error event).

source

pub fn value(self) -> Option<u8>

Returns the numeric value for this outcome.

source

pub fn index_category(self) -> Option<DataCategory>

Returns a dedicated category for indexing if this data can be converted to metrics.

This returns None for most data categories.

source

pub fn is_indexed(self) -> bool

Returns true if this data category is an indexed data category.

Trait Implementations§

source§

impl Clone for DataCategory

source§

fn clone(&self) -> DataCategory

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 DataCategory

source§

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

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

impl<'de> Deserialize<'de> for DataCategory

source§

fn deserialize<__D>( __deserializer: __D, ) -> Result<DataCategory, <__D as Deserializer<'de>>::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Display for DataCategory

source§

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

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

impl From<EventType> for DataCategory

source§

fn from(ty: EventType) -> DataCategory

Converts to this type from the input type.
source§

impl FromStr for DataCategory

source§

type Err = ()

The associated error which can be returned from parsing.
source§

fn from_str( string: &str, ) -> Result<DataCategory, <DataCategory as FromStr>::Err>

Parses a string s to return a value of this type. Read more
source§

impl Hash for DataCategory

source§

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

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 Ord for DataCategory

source§

fn cmp(&self, other: &DataCategory) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl PartialEq for DataCategory

source§

fn eq(&self, other: &DataCategory) -> 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 PartialOrd for DataCategory

source§

fn partial_cmp(&self, other: &DataCategory) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

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

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

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

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

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

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

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

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl Serialize for DataCategory

source§

fn serialize<__S>( &self, __serializer: __S, ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
source§

impl Copy for DataCategory

source§

impl Eq for DataCategory

source§

impl StructuralPartialEq for DataCategory

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 T)

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

impl<Q, K> Comparable<K> for Q
where Q: Ord + ?Sized, K: Borrow<Q> + ?Sized,

§

fn compare(&self, key: &K) -> Ordering

Compare self to key and return their ordering.
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
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> Same for T

source§

type Output = T

Should always be Self
source§

impl<T> Serialize for T
where T: Serialize + ?Sized,

source§

fn erased_serialize(&self, serializer: &mut dyn Serializer) -> Result<Ok, Error>

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> ToString for T
where T: Display + ?Sized,

source§

default fn to_string(&self) -> String

Converts the given value to a String. 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.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

source§

impl<T> RuleType for T
where T: Copy + Debug + Eq + Hash + Ord,