• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Which one will created first

 
Micheal John
Ranch Hand
Posts: 344
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
On calling create() on the home object, Which one will created first? EJBObject or Bean.. Whether it depends upon the type of bean? pls throw some inputs on it...
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Stateful session bean : EJBObject, instance
Stateless session bean : EJBObject. The instance creation is not related to the client's call.
MDB : not relevant
Entity : instance, EJBObject
 
Mike Pandey
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I do not think Entity Bean instance is created on client call. Like Stateless Session Beans, a pool is maintained from which a bean is taken out to represent a entity based on client call.
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Mike Pandey:
I do not think Entity Bean instance is created on client call. Like Stateless Session Beans, a pool is maintained from which a bean is taken out to represent a entity based on client call.


Yes , in case of entity beans , the beans are created beforehand by the container.Not related to client call.
 
Alex Sun
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Rahul Bhattacharjee:


Yes , in case of entity beans , the beans are created beforehand by the container.Not related to client call.


Can not agree with you.

For entity bean, create method is not for creat a instance of bean, it is create a new entity in database, how could container handle that without a call from client?
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Alex Sun:


Can not agree with you.



I was talking about the bean instances , which get created before any client operation.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic