• Post Reply Bookmark Topic Watch Topic
  • New Topic

Life Cycle  RSS feed

 
Rajeev Iyer
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi...
Which is the first method in the life cycle of stateless session bean?
some say it is the create while some others say it is ejbActivate.
Pls help..
Regards
 
Chris Mathews
Ranch Hand
Posts: 2712
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Class.newInstance() is the first method call on any EJB. Followed by setSessionContext() for Session Beans and then ejbCreate(). This will put the bean in the method-ready state. You can't possibly activate a bean that doesn't exist.
Besides, ejbActivate() is never called on stateless session beans because they are never passivated. That is what makes them stateless.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!