If you’re using a load balancer in front of your ASP.NET Core application you will need to provide it a route where it can verify that your application is still running. Here’s an overview of how you can implement implement Health Checks in ASP.NET Core.
Production is everything. If your software doesn’t perform in production, it doesn’t perform. Thankfully there’s a range of information that you can measure and monitor that helps you understand your production system and solve any issues that may arise. But where do you start and what should you monitor and measure? What are the tradeoffs between different approaches?
You likely have a service that does an occasional GET request to a page and looks at the HTML, or maybe just looks for an HTTP 200 Response. You can make these tests more robust by actually having the health check endpoint check deeper and then return something meaningful. That could be as simple as "Healthy" or "Unhealthy" or it could be a whole JSON payload that tells you what's working and what's not. It's up to you!