-
Nov 28th, 2007, 10:34 AM
#1
Best Solutions for catching Translated Exception
Hi,
I am trying to put exception translation to work. I've found information in http://forum.springframework.org/showthread.php?t=34260
but I am not understanding the solution, maybe because I am just to stupid.
My scenario uses JSF Page -> Backing Bean -> DAO. I am trying to put a try/catch in backing bean (inside called method) but it is not able to catch any Exception at all. I am also using OpenEntityManagerInView.
My DAO class is marked with @Repository and @Transaction, and as I said above, I would like to catch the exception in the Backing Bean.
Exception is being translated correctly, I am getting a DataIntegrityViolationException, my only problem is that the Exception is not get by the bean, but throwed to the screen.
I read about using Interceptor instead of tx-annotation, but I did not get the solution yet. Does it solve the problem about catching the exception? Are there more examples?
Thanks in advance
-
Nov 29th, 2007, 04:22 AM
#2
Sorry, bad day
I am now catching exception, but it was my mistake.
Too much work and a Try catch in a wrong place.
Sorry folks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules