1 write to _otlpContext
Aspire.Dashboard.Tests (1)
tests\Shared\Telemetry\InMemoryTelemetryRepository.cs (1)
110_otlpContext = new OtlpContext
26 references to _otlpContext
Aspire.Dashboard.Tests (26)
tests\Shared\Telemetry\InMemoryTelemetryRepository.cs (26)
117_logs = new(_otlpContext.Options.MaxLogCount); 118_traces = new(_otlpContext.Options.MaxTraceCount); 293if (_resources.Count >= _otlpContext.Options.MaxResourceCount) 295throw new InvalidOperationException($"Resource limit of {_otlpContext.Options.MaxResourceCount} reached. Resource '{key}' will not be added."); 304return new ResourceEntry(new OtlpResource(key.Name, key.InstanceId, uninstrumentedPeer, _otlpContext)); 387_otlpContext.Logger.LogInformation(ex, "Error adding resource."); 409if (!OtlpHelpers.TryGetOrAddScope(_logScopes, sl.Scope, _otlpContext, TelemetryType.Logs, out var scope)) 419var logEntry = CreateOtlpLogEntry(record, resourceView, scope, _otlpContext); 465_otlpContext.Logger.LogInformation(ex, "Error adding log entry."); 1910_otlpContext.Logger.LogInformation(ex, "Error adding resource."); 1930if (!OtlpHelpers.TryGetOrAddScope(resourceEntry.Meters, scopeMetric.Scope, _otlpContext, TelemetryType.Metrics, out var scope)) 1966Context = _otlpContext 1970_otlpContext.Logger.LogTrace("Added metric instrument '{InstrumentName}' for scope '{ScopeName}'.", instrument.Summary.Name, scope.Name); 1981_otlpContext.Logger.LogInformation(ex, "Error adding metric instrument {MetricName}.", metric.Name); 2005instrument.FindScope(dataPoint.Attributes).AddPointValue(dataPoint, _otlpContext); 2011_otlpContext.Logger.LogInformation(ex, "Error adding metric."); 2021instrument.FindScope(dataPoint.Attributes).AddPointValue(dataPoint, _otlpContext); 2027_otlpContext.Logger.LogInformation(ex, "Error adding metric."); 2036instrument.FindScope(dataPoint.Attributes).AddHistogramValue(dataPoint, _otlpContext); 2042_otlpContext.Logger.LogInformation(ex, "Error adding metric."); 2048_otlpContext.Logger.LogInformation("Error adding summary metrics. Summary is not supported."); 2052_otlpContext.Logger.LogInformation("Error adding exponential histogram metrics. Exponential histogram is not supported."); 2099_otlpContext.Logger.LogInformation(ex, "Error adding resource."); 2137if (!OtlpHelpers.TryGetOrAddScope(_traceScopes, scopeSpan.Scope, _otlpContext, TelemetryType.Traces, out var scope)) 2162var newSpan = CreateSpan(resourceView, span, trace, scope, _otlpContext); 2258_otlpContext.Logger.LogInformation(ex, "Error adding span.");