I’ve create a servlet to let me know if the webapp inside a Tomcat container is running or not. But now, I’m wondering if it is possible that one servlet responds and not another one? i.e. can two independent servlets (in the same webapp) be independently responsive or can I assume if one responds the other will respond?
Something that gives some clues but not enough information.
Thank you
Yes. The Servlet 3.0 spec tells among others the following:
It doesn’t say any line about that the other servlets should not be initialized or something. Just that the servlet is not been placed into active service.
Update as per the comments: the same spec tells the following whenever a successfully initialized servlet throws an exception during the service: