The main exceptions you have to know for the exam are five application exceptions:
* CreateException
* RemoveException
* FinderException
* ObjectNotFoundException
* DuplicateKeyException
and...
EJBException and RemoteException
and...
NoSuchObjectException
NoSuchObjectLocalException
You should also know about TrasactionRollbackException / TransactionRolledbackLocalException and TransactionRequiredException / TransactionRequiredLocalException
You should know about NamingException and
IllegalStateException.
You should know the circumstances under which something can throw an exception, and *especially* you must know the implications of an exception.
Application Exception: no rollback, bean lives. If you want a rollback, YOU need to do it either via your UserTransaction (BMT) or by calling setRollbackOnly() on your context (CMT).
System Exception: transaction automatically rolled back, bean is destroyed (without getting an ejbRemove() or unset<something>Context() call, and the exception is logged.
In general, if you know what is and is not allowed in the spec, then you can usually figure out which exceptions might be thrown. In other words, it is far more important to know that something WILL throw an exception rather than to know exactly which exception is thrown.
The Application exceptions are the ones where you should know the exact circumstances under which these exceptions can be thrown, and what it might mean to the bean and to the client.
cheers,
Kathy