Table of Contents

Class CatalogMetric

Namespace
Typhon.Protocol
Assembly
Typhon.Protocol.dll

A metric the server publishes in its STATS block (W25).

public sealed class CatalogMetric
Inheritance
CatalogMetric
Inherited Members

Constructors

CatalogMetric()

public CatalogMetric()

Fields

CounterKind

The Kind of a cumulative count, modulo 2³², so a missed emission loses nothing.

public const string CounterKind = "counter"

Field Value

string

GaugeKind

The Kind of a windowed value.

public const string GaugeKind = "gauge"

Field Value

string

ServerScope

The Scope of a metric encoded once for every subscriber.

public const string ServerScope = "server"

Field Value

string

SessionScope

The Scope of a metric with a value per session.

public const string SessionScope = "session"

Field Value

string

Properties

Codec

How each value is encoded.

public CatalogCodec Codec { get; init; }

Property Value

CatalogCodec

Idx

The wire index: built-in metrics keep their reserved index; application metrics are numbered from 32 in ordinal name order.

public int Idx { get; init; }

Property Value

int

Kind

CounterKind, or absent for GaugeKind.

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public string Kind { get; init; }

Property Value

string

Labels

For a vector metric, one label per value, in wire order — the order is data and is never sorted. Absent for a scalar.

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public string[] Labels { get; init; }

Property Value

string[]

Name

The metric's dotted name, for example typhon.tick.p99. The typhon. prefix is reserved for built-ins.

public string Name { get; init; }

Property Value

string

Scope

SessionScope, or absent for ServerScope.

[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public string Scope { get; init; }

Property Value

string

Unit

The unit the value is expressed in, for example ms.

public string Unit { get; init; }

Property Value

string