-
Notifications
You must be signed in to change notification settings - Fork 74
Healthcheck
ZhangYang edited this page Jul 12, 2019
·
1 revision
Health Check Config Readiness and liveness probes
var healthCheckResponseWriterProvider = new HealthCheckerResponseProvider(env);
app.UseHealthChecks("/health/ready", new HealthCheckOptions
{
Predicate = (check) => check.Tags.Contains("ready"),
ResponseWriter = healthCheckResponseWriterProvider.Writer
});
app.UseHealthChecks("/health/live", new HealthCheckOptions
{
Predicate = (_) => false,
ResponseWriter = healthCheckResponseWriterProvider.Writer
});
Liveness endpoint used for indicating application is startup.
Request /health/live
{
message: "Hello, Welcome to RestAirline Api",
environmentName: "Development",
localDate: "2019-07-12T23:40:26.324795+08:00",
utcDate: "2019-07-12T15:40:26.324795Z",
status: "Healthy"
}
Readiness endpoint used for indicating application is ready to start accepting traffic.
Request /health/ready
{
message: "Hello, Welcome to RestAirline Api",
environmentName: "Development",
localDate: "2019-07-12T23:41:45.861611+08:00",
utcDate: "2019-07-12T15:41:45.861611Z",
status: "Healthy"
}
-
Getting started
-
ASP.NET Core
-
Docker & Docker-compose
-
Hypermedia API
-
EntityFramework ReadModel
-
MongoDb ReadModel
-
Elasticseach ReadModel
-
DDD
-
Domain