File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes remove method(entity bean ) Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Professional Certification » Architect Certification (SCEA/OCMJEA)
Reply Bookmark "remove method(entity bean )" Watch "remove method(entity bean )" New topic
Author

remove method(entity bean )

Timber Lee
Ranch Hand

Joined: Oct 14, 2002
Posts: 157
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?


SCJP<br />SCWCD<br />SCEA
Andrew Turnbull
Greenhorn

Joined: Nov 05, 2002
Posts: 4
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

Joined: Sep 19, 2001
Posts: 71
It goes to the pooled state when you call ejb remove


Shankar<br />Post mock questions in<br /><a href="http://groups.yahoo.com/group/scea_mock" target="_blank" rel="nofollow">http://groups.yahoo.com/group/scea_mock</a>
Claudio Malso
Ranch Hand

Joined: Nov 05, 2002
Posts: 50
Originally posted by Shankar Ranganathan:
It goes to the pooled state when you call ejb remove

... and the EJBObject become invalidated.


Claudio
 
IntelliJ Java IDE
 
subject: remove method(entity bean )
 
Threads others viewed
Need Clarification-REgarding Sharpen your Pencil
RemoveException or EJBException
remove() is not removing the record from the database
Dout about EJBHome.remove(Handle h) for entity beans
Session and Entity beans
developer file tools