Skip to content

AgentPrismObservabilityOptions

Namespace AgentPrism · Assembly AgentPrism.Core.dll

Defines telemetry collection and persistence options.

public sealed class AgentPrismObservabilityOptions

objectAgentPrismObservabilityOptions

object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

AgentPrism does not take over the pipeline: the consumer’s OTLP exporter continues to run. These options only control what AgentPrism writes to its own span store.

public AgentPrismObservabilityOptions()

Gets or sets whether failed run spans are persisted regardless of sampling ratio.

public bool AlwaysPersistFailures { get; set; }

bool

Gets or sets whether the agentprism.quota.usage and agentprism.quota.limit observable gauges are enabled.

public bool EnableQuotaUsageGauge { get; set; }

bool

Disabled by default under the no-surprises rule because the gauge reads the database. Unlike the cost counter, this consumes additional resources and must be explicitly requested.

Gets or sets whether span and metric creation is enabled. When disabled, no Activity starts and no measurement is recorded.

public bool Enabled { get; set; }

bool

Gets or sets whether the agentprism.agent.version tag is added to spans and the agentprism.runs and agentprism.run.duration metrics.

public bool IncludeAgentVersionTag { get; set; }

bool

Defaults to true. A version number creates dozens of time series per agent over time, which is acceptable cardinality. Deployments that change versions very frequently can disable it.

Gets or sets the largest span count held in memory for one run. Excess spans are dropped and a warning is logged.

public int MaxSpansPerRun { get; set; }

int

The sampling decision is made when a run finishes, when success or failure is known. Spans remain in memory until then. This limit bounds memory use by the concurrent run count.

Gets or sets whether spans are written to ITraceStore. When disabled, spans are still created and sent to the consumer exporter, but are not written to AgentPrism’s own store.

public bool PersistSpans { get; set; }

bool

Gets or sets the quota-gauge cache refresh interval. Consecutive polls do not reach the database before this interval elapses.

public TimeSpan QuotaUsageRefreshInterval { get; set; }

TimeSpan

Gets or sets whether request and response text is written to spans. Disabled by default because this content can contain personal data.

public bool RecordSensitiveData { get; set; }

bool

Gets or sets the fraction from 0 to 1 of successful run spans to persist. Defaults to 0.1, or one tenth.

public double SuccessSampleRatio { get; set; }

double

Persisting every span bottlenecks the database at high volume. Failed runs are valuable for debugging and are separately protected by AgentPrismObservabilityOptions.AlwaysPersistFailures.