Table of Contents

Class EcsMetricsExporter

Namespace
Typhon.Engine
Assembly
Typhon.Engine.dll

Exports ECS metrics to OpenTelemetry via Meter: per-archetype EntityMap gauges and per-component transient memory gauges. All metrics are zero-cost reads of existing fields — no new Interlocked overhead on hot paths.

public sealed class EcsMetricsExporter : IDisposable
Inheritance
EcsMetricsExporter
Implements
Inherited Members

Constructors

EcsMetricsExporter(DatabaseEngine)

Creates the exporter and registers the ECS observable instruments on a new Meter. The instruments read live engine state on collection; no work is done until an OTel consumer polls them.

public EcsMetricsExporter(DatabaseEngine dbe)

Parameters

dbe DatabaseEngine

The engine whose archetype and component-table state is sampled. Must not be null.

Exceptions

ArgumentNullException

dbe is null.

Fields

MeterName

The OpenTelemetry Meter name under which all ECS instruments are published.

public const string MeterName = "Typhon.ECS"

Field Value

string

MeterVersion

The Meter version reported to OpenTelemetry.

public const string MeterVersion = "1.0.0"

Field Value

string

Properties

Meter

The OpenTelemetry Meter that owns the ECS observable instruments.

public Meter Meter { get; }

Property Value

Meter

Methods

Dispose()

Disposes the underlying Meter, unregistering every ECS instrument.

public void Dispose()