2 writes to _app
Aspire.Dashboard (2)
DashboardWebApplication.cs (2)
168
_app
= builder.Build();
283
_app
= builder.Build();
36 references to _app
Aspire.Dashboard (36)
DashboardWebApplication.cs (36)
169
_dashboardOptionsMonitor =
_app
.Services.GetRequiredService<IOptionsMonitor<DashboardOptions>>();
172
Services =
_app
.Services;
285
_dashboardOptionsMonitor =
_app
.Services.GetRequiredService<IOptionsMonitor<DashboardOptions>>();
287
Services =
_app
.Services;
295
_app
.UseRequestLocalization(new RequestLocalizationOptions()
301
_app
.Lifetime.ApplicationStarted.Register(() =>
308
var corsOptions =
_app
.Services.GetRequiredService<IOptions<CorsOptions>>().Value;
344
var options =
_app
.Services.GetRequiredService<IOptionsMonitor<DashboardOptions>>().CurrentValue;
349
var isContainer =
_app
.Configuration.GetBool("DOTNET_RUNNING_IN_CONTAINER") ?? false;
356
var telemetryService =
_app
.Services.GetRequiredService<DashboardTelemetryService>();
372
_app
.Use(async (context, next) =>
391
_app
.UseCors();
394
_app
.UseMiddleware<ValidateTokenMiddleware>();
397
if (!
_app
.Environment.IsDevelopment())
399
_app
.UseExceptionHandler("/error");
402
_app
.UseHsts();
406
_app
.UseResponseCompression();
408
_app
.UseStatusCodePagesWithReExecute("/error/{0}");
412
_app
.UseHttpsRedirection();
415
_app
.UseStaticFiles(new StaticFileOptions()
430
_app
.UseAuthorization();
432
_app
.UseMiddleware<BrowserSecurityHeadersMiddleware>();
433
_app
.UseAntiforgery();
435
_app
.MapRazorComponents<App>().AddInteractiveServerRenderMode();
438
_app
.MapHttpOtlpApi(dashboardOptions.Otlp);
441
_app
.MapGrpcService<OtlpGrpcMetricsService>();
442
_app
.MapGrpcService<OtlpGrpcTraceService>();
443
_app
.MapGrpcService<OtlpGrpcLogsService>();
445
_app
.MapDashboardApi(dashboardOptions);
446
_app
.MapDashboardHealthChecks();
447
_app
.MapDashboardBlazor();
452
return
_app
.Services.GetRequiredService<ILoggerFactory>().CreateLogger<DashboardWebApplication>();
850
_app
.Run();
857
return
_app
.StartAsync(cancellationToken);
863
return
_app
.StopAsync(cancellationToken);
868
return
_app
.DisposeAsync();