Win a copy of High Performance Python for Data Analytics this week in the Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Jj Roberts
  • Carey Brown
Bartenders:
  • salvin francis
  • Frits Walraven
  • Piet Souris

ejbRemove calling ejbPassivation

 
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
session beans:
a call to remove a passivated bean will NOT invoke ejbActivate().
HFEJB - question 7 page 253
Entity beans:
a call to remove a passivated bean will invoke ejbActivate().
HFEJB - question 16 page 371
Just want to confirm that the above summary is accurate.
- walk rustin
 
Ranch Hand
Posts: 1066
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Walker, I think you are right.
But ejbActivate() and ejbPassivate() mean different things for
SFSB and Entity beans.
ejbActivate()/ejbPassivate() for SFSB involves serialization/deserialiation of the bean's state to a flat file to conserve resources, while Entity bean's ejbActivate()/ejbPassivate() involves the bean coming out the bean instance pool and going back to the pool ...
...IMO, comparing them conceptually could be confusing sometimes.
 
Ranch Hand
Posts: 143
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Remember for entity beans you cannot really remove a bean. the question actually states "when invoking ejbRemove()". This means that if the row is already not loaded into an bean instance then the container has to first load the data into a bean from the pool and this wud require calling ejbActivate and ejbLoad. Also the question says "might". If it wud have said "must" then none of the answer choices wud have sufficed.
Please see this post for a further discussion on this topic
https://coderanch.com/t/158574/java-EJB-SCBCD/certification/Additional-methods-which-might-called
 
reply
    Bookmark Topic Watch Topic
  • New Topic