Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Exception handling in Faces Filter  RSS feed

 
Adrian Bustos
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everyone, I've got a little problem regarding exception handling in a custom filter I wrote.

This was working OK until I start using a4j:queue control.

If no exception is raised during de request call, all events are raised (onbeforedomupdate, onrequestqueue, onrequestdequeue, oncomplete and onerror) but "onerror" and "oncomplete" won't raise when an exception is thrown. This is because I treat the exception and do not invoke the "doFilter" method inside the catch.

If I'd invoke the doFilter method those 2 events (oncomplete and onerror) are executed, but the Error 500 pages appears on the client side and that's something I want to avoid.

So... I came to the theory that the doFilter method should be invoked but before that these two objects servletRequest, servletResponse must be treated so the servlet won't fire an Error 500 page redirection.

Any ideas?
 
Adrian Bustos
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok, I think I solved it


 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!