Skip to content

AgentFrameworkMetricsOptions

NexusLabs.Needlr.AgentFramework

NexusLabs.Needlr.AgentFramework.Diagnostics

AgentFrameworkMetricsOptions Class

Configuration options for the agent framework's OpenTelemetry metrics and tracing.

public sealed class AgentFrameworkMetricsOptions

Inheritance System.Object 🡒 AgentFrameworkMetricsOptions

Remarks

Consumers that have existing dashboards keyed to a specific meter name (e.g., "BrandGhost.Agents") can set MeterName to match, avoiding a dashboard migration when adopting Needlr's IAgentMetrics.

Configure via the syringe:

.UsingAgentFramework(af => af
    .ConfigureMetrics(o => o.MeterName = "MyApp.Agents"))

Properties

AgentFrameworkMetricsOptions.ActivitySourceName Property

The name used for the System.Diagnostics.ActivitySource that emits distributed tracing spans. Defaults to MeterName when null.

public string? ActivitySourceName { get; set; }

Property Value

System.String

AgentFrameworkMetricsOptions.MeterName Property

The name used for the System.Diagnostics.Metrics.Meter that emits counters and histograms. Defaults to "NexusLabs.Needlr.AgentFramework".

public string MeterName { get; set; }

Property Value

System.String