This content has been marked as final.
Show 1 reply
-
1. Re: EJB Design Question:
minamoto Oct 24, 2001 5:24 AM (in response to nuanda)Hi,
As a inhouse developer, I'd take the ugly database constrains option because it is so easy to implement/test and clients can retry the operation when they catch the ejb exception. I accept this if the transaction is relatively short.
Otherwise, it is possible I might define an application exception for constratin violation and set 'requiresNew' transaction attribute to the entity. When a session bean catches the exception from the entity, the session bean can control the whole transaction with setRollbackOnly method.
Miki