This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
For a EJB 2.1 (and earlier) entity bean, the transaction attributes are specified for the methods defined in the bean�s component interface and all the direct and indirect superinterfaces of the component interface, excluding the getEJBHome, getEJBLocalHome, getHandle,getPrimaryKey, and isIdentical methods; for the methods defined in the bean�s home interface and all the direct and indirect superinterfaces of the home interface, excluding the getEJBMetaData and getHomeHandle methods specific to the remote home interface;and for the timeout callback method, if any.
Does this implies that transaction attributes can be set for the remove() methods of the home and remote interfaces of the Entity bean 2.1 if so, tell me why would we include a remove method to a transaction.
when you really want something, all the universe always conspires in your favour.<br /> <br />SCJP1.5-77%<br />SCWCD-89%
remove() in Entity Beans corresponds to deleting a record in the DB. Since this is a DB operation, it need to be in a transaction. However remove() in Session Beans has nothing to do with the DB. Hence it is not required to be in a transactional enclosure.