There is no ejbCreate() method in the session bean interface but bean developer has to implement the corresponding the ejbCreate() method in the stateful session bean or ejbCreate() in case of stateless session bean. Why this assumption is left to the bean developer.
By chance if the bean developer forget to define the ejbCreate() in a bean class or create() in home interface of a Stateless Session Bean. What will happen?
Lets play by rules !! For Stateless Session Bean, the "Bean Rule" states we MUST have a create() in the home interface and this should be matched with a corresponding/matching ejbCreate()method in the Bean Class.
A CreateException will be thrown back to the client if the Bean Provider forgets to declare the above methods
- Sundar, IBM India.
Story like this gets better after being told a few times. Or maybe it's just a tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop