Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Calling remove(Object) on a session bean...

 
Sub swamy
Ranch Hand
Posts: 121
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When we call remove(Object object) method of a session bean remote home interface(or local interface for that matter) - to remove a session object - do we get a RemoveException or a RemoteException(EJBException) ?

One version of errata that i have says RemoteException while HFEJB says RemoveException would be thrown.
 
Frederic Esnault
Ranch Hand
Posts: 284
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi !

From the EJB spec :

Because session objects do not have primary keys that are accessible to clients, invoking the javax.ejb.EJBHome.remove(Object primaryKey) method on a session results in the javax.ejb.RemoveException.

HFE is right
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic