2 instantiations of TelemetryRepository
Aspire.Dashboard.Components.Tests (1)
tests\Shared\Telemetry\TelemetryTestHelpers.cs (1)
251
var repository = new
TelemetryRepository
(
Aspire.Dashboard.Tests (1)
tests\Shared\Telemetry\TelemetryTestHelpers.cs (1)
251
var repository = new
TelemetryRepository
(
113 references to TelemetryRepository
Aspire.Dashboard (47)
Components\Controls\ResourceActions.razor.cs (2)
33
public required TelemetryRepository
TelemetryRepository
{ get; set; }
83
var hasTelemetryApplication =
TelemetryRepository
.GetApplicationByCompositeName(Resource.Name) != null;
Components\Controls\TreeMetricSelector.razor.cs (1)
23
public required TelemetryRepository
TelemetryRepository
{ get; init; }
Components\Dialogs\FilterDialog.razor.cs (1)
27
public required TelemetryRepository
TelemetryRepository
{ get; init; }
Components\Pages\Resources.razor.cs (4)
35
public required TelemetryRepository
TelemetryRepository
{ get; init; }
159
_applicationUnviewedErrorCounts =
TelemetryRepository
.GetApplicationUnviewedErrorLogsCount();
166
_logsSubscription =
TelemetryRepository
.OnNewLogs(null, SubscriptionType.Other, async () =>
168
var newApplicationUnviewedErrorCounts =
TelemetryRepository
.GetApplicationUnviewedErrorLogsCount();
Components\Pages\StructuredLogs.razor.cs (9)
53
public required TelemetryRepository
TelemetryRepository
{ get; init; }
113
if (DashboardOptions.Value.TelemetryLimits.MaxLogCount == logs.TotalItemCount && !
TelemetryRepository
.HasDisplayedMaxLogLimitMessage)
123
TelemetryRepository
.HasDisplayedMaxLogLimitMessage = true;
131
TelemetryRepository
.MarkViewedErrorLogs(ViewModel.ApplicationKey);
186
_applicationsSubscription =
TelemetryRepository
.OnNewApplications(() => InvokeAsync(() =>
206
_applications =
TelemetryRepository
.GetApplications();
232
_logsSubscription =
TelemetryRepository
.OnNewLogs(PageViewModel.SelectedApplication.Id?.GetApplicationKey(), SubscriptionType.Read, async () =>
291
PropertyKeys =
TelemetryRepository
.GetLogPropertyKeys(PageViewModel.SelectedApplication.Id?.GetApplicationKey()),
293
GetFieldValues =
TelemetryRepository
.GetLogsFieldValues
Components\Pages\TraceDetail.razor.cs (5)
44
public required TelemetryRepository
TelemetryRepository
{ get; init; }
136
_applications =
TelemetryRepository
.GetApplications();
142
_trace =
TelemetryRepository
.GetTrace(TraceId);
162
_tracesSubscription =
TelemetryRepository
.OnNewTraces(_trace.FirstSpan.Source.ApplicationKey, SubscriptionType.Read, () => InvokeAsync(async () =>
238
trace ??=
TelemetryRepository
.GetTrace(traceId);
Components\Pages\Traces.razor.cs (8)
52
public required TelemetryRepository
TelemetryRepository
{ get; init; }
117
if (DashboardOptions.Value.TelemetryLimits.MaxTraceCount == traces.TotalItemCount && !
TelemetryRepository
.HasDisplayedMaxTraceLimitMessage)
127
TelemetryRepository
.HasDisplayedMaxTraceLimitMessage = true;
152
_applicationsSubscription =
TelemetryRepository
.OnNewApplications(callback: () => InvokeAsync(workItem: () =>
179
_applications =
TelemetryRepository
.GetApplications();
199
_tracesSubscription =
TelemetryRepository
.OnNewTraces(selectedApplicationKey, SubscriptionType.Read, async () =>
306
PropertyKeys =
TelemetryRepository
.GetTracePropertyKeys(PageViewModel.SelectedApplication.Id?.GetApplicationKey()),
308
GetFieldValues =
TelemetryRepository
.GetTraceFieldValues
Components\ResourcesGridColumns\UnreadLogErrorsBadge.razor.cs (3)
22
public required TelemetryRepository
TelemetryRepository
{ get; init; }
36
var application =
TelemetryRepository
.GetApplicationByCompositeName(resource.Name);
47
var applications =
TelemetryRepository
.GetApplications();
DashboardWebApplication.cs (1)
239
builder.Services.AddSingleton<
TelemetryRepository
>();
Model\StructuredLogsViewModel.cs (2)
12
private readonly
TelemetryRepository
_telemetryRepository;
22
public StructuredLogsViewModel(
TelemetryRepository
telemetryRepository)
Model\TracesViewModel.cs (2)
12
private readonly
TelemetryRepository
_telemetryRepository;
21
public TracesViewModel(
TelemetryRepository
telemetryRepository)
Otlp\OtlpLogsService.cs (2)
13
private readonly
TelemetryRepository
_telemetryRepository;
15
public OtlpLogsService(ILogger<OtlpLogsService> logger,
TelemetryRepository
telemetryRepository)
Otlp\OtlpMetricsService.cs (2)
13
private readonly
TelemetryRepository
_telemetryRepository;
15
public OtlpMetricsService(ILogger<OtlpMetricsService> logger,
TelemetryRepository
telemetryRepository)
Otlp\OtlpTraceService.cs (2)
13
private readonly
TelemetryRepository
_telemetryRepository;
15
public OtlpTraceService(ILogger<OtlpTraceService> logger,
TelemetryRepository
telemetryRepository)
Otlp\Storage\Subscription.cs (2)
15
private readonly
TelemetryRepository
_telemetryRepository;
30
public Subscription(string name, ApplicationKey? applicationKey, SubscriptionType subscriptionType, Func<Task> callback, Action unsubscribe, ExecutionContext? executionContext,
TelemetryRepository
telemetryRepository)
Otlp\Storage\TelemetryRepository.cs (1)
58
var logger = loggerFactory.CreateLogger(typeof(
TelemetryRepository
));
Aspire.Dashboard.Components.Tests (15)
Pages\MetricsTests.cs (4)
85
var
telemetryRepository = Services.GetRequiredService<
TelemetryRepository
>();
130
var
telemetryRepository = Services.GetRequiredService<
TelemetryRepository
>();
Pages\StructuredLogsTests.cs (1)
176
Services.AddSingleton<
TelemetryRepository
>();
Pages\TraceDetailsTests.cs (4)
42
var
telemetryRepository = Services.GetRequiredService<
TelemetryRepository
>();
74
Assert.Equal(nameof(
TelemetryRepository
.OnNewTraces), t.Name);
110
Services.AddSingleton<
TelemetryRepository
>();
Shared\MetricsSetupHelpers.cs (2)
40
context.Services.AddSingleton<
TelemetryRepository
>();
75
context.Services.AddSingleton<
TelemetryRepository
>();
Shared\ResourceSetupHelpers.cs (1)
19
context.Services.AddSingleton<
TelemetryRepository
>();
Shared\StructuredLogsSetupHelpers.cs (1)
19
context.Services.AddSingleton<
TelemetryRepository
>();
tests\Shared\Telemetry\TelemetryTestHelpers.cs (2)
220
public static
TelemetryRepository
CreateRepository(
251
var
repository = new TelemetryRepository(
Aspire.Dashboard.Tests (51)
TelemetryRepositoryTests\ApplicationTests.cs (5)
19
var
repository = CreateRepository();
61
var
repository = CreateRepository();
99
var
repository = CreateRepository();
131
var
repository = CreateRepository();
149
private static void AddResource(
TelemetryRepository
repository, string name, string? instanceId = null)
TelemetryRepositoryTests\LogTests.cs (17)
35
var
repository = CreateRepository();
98
var
repository = CreateRepository();
139
var
repository = CreateRepository();
201
var
repository = CreateRepository();
276
var
repository = CreateRepository();
328
var
repository = CreateRepository();
381
var
repository = CreateRepository();
418
var
repository = CreateRepository();
437
var
repository = CreateRepository();
450
var
repository = CreateRepository();
534
var
repository = CreateRepository();
574
var
repository = CreateRepository();
619
var
repository = CreateRepository(maxAttributeCount: 5, maxAttributeLength: 16);
709
var
repository = CreateRepository(subscriptionMinExecuteInterval: minExecuteInterval, loggerFactory: loggerFactory);
783
var
repository = CreateRepository();
830
var
repository = CreateRepository();
929
var
repository = CreateRepository();
TelemetryRepositoryTests\MetricsTests.cs (6)
26
var
repository = CreateRepository();
99
var
repository = CreateRepository(maxAttributeCount: 5, maxAttributeLength: 16);
213
var
repository = CreateRepository(maxAttributeCount: 5, maxAttributeLength: 16);
318
var
repository = CreateRepository();
426
var
repository = CreateRepository(maxMetricsCount: 3);
505
var
repository = CreateRepository();
TelemetryRepositoryTests\TraceTests.cs (21)
34
var result =
TelemetryRepository
.ConvertSpanKind(value);
42
var
repository = CreateRepository();
102
var
repository = CreateRepository(loggerFactory: factory);
155
var
repository = CreateRepository();
210
var
repository = CreateRepository();
265
var
repository = CreateRepository();
343
var
repository = CreateRepository();
465
var
repository = CreateRepository();
518
var
repository = CreateRepository();
595
var
repository = CreateRepository();
704
var
repository = CreateRepository();
764
var
repository = CreateRepository(maxAttributeCount: 5, maxAttributeLength: 16, maxSpanEventCount: 5);
859
var
repository = CreateRepository();
903
var
repository = CreateRepository(maxTraceCount: MaxTraceCount);
958
private static void AddTrace(
TelemetryRepository
repository, string traceId, DateTime startTime)
1014
var
repository = CreateRepository();
1064
var
repository = CreateRepository();
1140
var
repository = CreateRepository();
1240
var
repository = CreateRepository();
1304
var
repository = CreateRepository();
1420
var
repository = CreateRepository();
tests\Shared\Telemetry\TelemetryTestHelpers.cs (2)
220
public static
TelemetryRepository
CreateRepository(
251
var
repository = new TelemetryRepository(