(this WebApplication app)
| 88 | } |
| 89 | |
| 90 | public static WebApplication MapDefaultEndpoints(this WebApplication app) |
| 91 | { |
| 92 | // Adding health checks endpoints to applications in non-development environments has security implications. |
| 93 | // See https://aka.ms/dotnet/aspire/healthchecks for details before enabling these endpoints in non-development environments. |
| 94 | if (app.Environment.IsDevelopment()) |
| 95 | { |
| 96 | // All health checks must pass for app to be considered ready to accept traffic after starting |
| 97 | app.MapHealthChecks("/health"); |
| 98 | |
| 99 | // Only health checks tagged with the "live" tag must pass for app to be considered alive |
| 100 | app.MapHealthChecks("/alive", new HealthCheckOptions |
| 101 | { |
| 102 | Predicate = r => r.Tags.Contains("live") |
| 103 | }); |
| 104 | } |
| 105 | |
| 106 | return app; |
| 107 | } |
| 108 | } |
nothing calls this directly
no outgoing calls
no test coverage detected