Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

EJBHome.remove

 
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 194
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic