I use Apache Myfaces 2.2 on WebSphere Application Server.
I have a JSF page, which “test” the conenction to filesystem and database.
When the connection fails, I want to return another HTTP Status Code.
How can I do this with JSF?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Try response.setStatus();
for more details this link will be helpful :
https://stackoverflow.com/a/16777616/1763602