
Originally Posted by
harasta
I'm relatively new in Spring Security. Maybe I don't get some detail. But how can be worth to ensure if CAS URL displays any page in case of CAS is down. No page displays, even no HTTP error returns.
It really depends on your infrastructure on how to best go about this. The The simplest example is to ensure you have specified an error page in your web.xml. Another example is to have a Filter that does something like...
Code:
public void doFilter(ServletRequest req,ServletResponse resp,FilterChain chain)
throws IOException, ServletException {
try {
chain.doFilter(req,resp);
}catch(Throwable t) {
// log error
// forward or render a pretty error page
}
}
Yet another example, is to have your load balancer have a health check on your application. If the health check fails have the load balancer display an error page. As you can see there are a number of different ways to go about it. The main thing is if a user enters a URL that you own, then the page is rendered or an appropriate error message is displayed.
HTH,