Monitor health of web application (runs in tomcat server)
I want to monitor the health of my web app that runs in tomcat. Basically, the application processes user requests and updates some info in the database and the iptable rules in my linux box. When i just poll port 80 for health check, the app responds even when the app is not fully operational. I mean even when deadlocks appear and the db interface fails, the app responds for the polling.
So, I plan to write a simple PollHandlerServlet which will receive the request, add/delete/update dummy values in the db and add/delete dummy iptable rules and when all these operations execute properly, the servlet will return a success message . Is this suff开发者_如何学JAVAicient? Anything overlooked? Please advice.
精彩评论