Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

A question from HFEJB coffee cram mock exam

 
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, everyone,

Page 364, HFEJB, there is a question saying:

What's true for a CMP bean in the ready state?

A. Its ejbLoad() can be called directly after ejbStore.
B. Its ejbStore() can be called directly after a business method.
C. One of its business methods can be called directly after ejbStore.
D. None of the above.


The answer says that load, store and business methods can be called
by the container in any order.
I am confused about that. Can anyone give me an example to explain?


by the way, the answer mentioned (spec: 169), does it means Page169 in
Enterprise JavaBeans Specification Page169?

I cannot find anything
talking about it in the Spec P169. Please help.


Thank you.
 
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Hi, everyone,

Page 364, HFEJB, there is a question saying:

What's true for a CMP bean in the ready state?

A. Its ejbLoad() can be called directly after ejbStore.
B. Its ejbStore() can be called directly after a business method.
C. One of its business methods can be called directly after ejbStore.
D. None of the above.


The answer says that load, store and business methods can be called
by the container in any order.
I am confused about that. Can anyone give me an example to explain?


by the way, the answer mentioned (spec: 169), does it means Page169 in
Enterprise JavaBeans Specification Page169?

I cannot find anything
talking about it in the Spec P169. Please help.


Thank you.



ejbLoad to get the updated data from Database(or other persistent storage) and ejbStore to store the date. These are used for automatic syncronization which is feature of entity beans.

these both can be called in any order. but ejbLoad has to be called after ejbActivate and ejbStore before ejbPassivate. see PgNo 353 in HFEJB.
 
I knew that guy would be trouble! Thanks tiny ad!
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic