I have a web application, for which I have an isalive page that gets hit on a regular basis (monitoring) to make sure my application is working (or is alive as the name suggests).
In general, this isalive functionality/page is very light in terms of processing. It checks things that the application depends on like SQL connectivity, Fileshare connectivity etc (on top of obviously verifying that the app itself on the web server can server this current isalive request).
Currently we use HTTP status code 200 for success and HTTP status code 500 for failure (we set the HTTP status code on response). But some how I feel, this is not accurate (in my opinion), since HTTP status code 500 is internal server error, and may not be accurately representing failure condition, since failure could be thrown, not only due to web level failure, but could also be due to dependency failure like SQL, FS connectivity checks.
Since this seems like a fairly standard use case for many, what is the industry standard for this? Am I doing it right? Suggestions or how you have been handling this would be much appreciated.