This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes EJBHome.remove Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "EJBHome.remove" Watch "EJBHome.remove" New topic
Author

EJBHome.remove

Kalyan Anand
Ranch Hand

Joined: Feb 07, 2007
Posts: 194
What must be the expected behavior when EJBHome.remove is called with null as the parameter i.e. EJBHome.remove(null) on a Stateless Session Bean Home ?
Kalyan Anand
Ranch Hand

Joined: Feb 07, 2007
Posts: 194
Here are the behaviors I see in OC4J 10.1.3. Wondering with the behaviors. What do you think must be the behaviors in the following scenarios ???


SFSB

1. EJBObject.remove() followed by invoking business method on Bean = java.rmi.NoSuchObjectException
2. EJBHome.remove(Object pk) = javax.ejb.RemoveException
3. EJBHome.remove(null) = NullPointerException (at com.evermind.server.ejb.RemoteStatefulSessionEJBHome.remove(RemoteStatefulSessionEJBHome.java:25)
)

SLSB

1. EJBObject.remove() followed by invoking business method on Bean = No exception is thrown from remove and the business method executes successfully !

2. EJBHome.remove(Object pk)= javax.ejb.RemoveException
3. EJBHome.remove(null) = No execption is thrown
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: EJBHome.remove
 
Similar Threads
EJBHome.remove(Object primaryKey)
Dout about EJBHome.remove(Handle h) for entity beans
mock exam question
What's different between remove(para) of EJBHome and remove( ) of EJBRemote??
about EJBHome.remove