I have a web application which needs to do some checking before user is allowed to use the application. I want to throw some kind of exception that undeploys or kills the the web application if these checks fails, however I am not sure if there are any exceptions I can throw that kills the web application RuntimeException()?
or if I have to System.exit(0)
What is the correct way to kill/stop a web application by force?