This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

remove method(entity bean )

 
Timber Lee
Ranch Hand
Posts: 157
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I read some articles that come from internet, but sometimes their difference in describing some concept really confuses me.hope to get clear
after client invokes the remove method within Home interface , does the entity bean firstly go into passivate? what are the steps of entity ejb when client call its remove method?
 
Andrew Turnbull
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there.
No!
As far as I can tell from my SCEA notes, the sole purpose of calling a remove method (be it from on a home interace or a remote or local interface) is to remove some specific entity data from the underlying persistent store (database).
Once that data has been removed, then you can no longer have an entity bean that represents that data.
Passivating an entity bean is a technique used by the container to manage pooling and load balancing. A container passivates a bean instance in order to free up resources, but still save the state of that bean to be activated and used at some point in the future.
If you are destroying the data that a bean represents, then it makes no sense to first store away that bean's state for future use!
The CMP and BMP entity bean sequence diagrams (Mastering EJB 2, Appendix E) show all the actions and parties involved in both bean passivation and removal - they should help explain this.
Cheers, Andy
[ February 09, 2003: Message edited by: Andrew Turnbull ]
 
Shankar Ranganathan
Ranch Hand
Posts: 71
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It goes to the pooled state when you call ejb remove
 
Claudio Malso
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Shankar Ranganathan:
It goes to the pooled state when you call ejb remove

... and the EJBObject become invalidated.
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic