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

HF-EJB book. Page 366 - Q18, Need explaination

 
Srivatsa Katta
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers,

Can someone explain me this question in HF-EJB book. Page 366 - Q18



Which method(s) run in the transaction context of the method that causes their invocation? (Choose all that apply)

A) ejbLoad();
B) ejbRemove();
C) ejbSelect();
D) ejbActivate();
E) ejbPassivate();
F) setEntityContext();



Thanks a lot in advance.

Regards,
Tripter
 
Purav Gandhi
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Let me explain you the most obvious of the three answers.

ejbLoad(), ejbRemove(), ejbSelect()

These methods should always run in the transaction context of the method that calls it as 2 & 3 operations are database operations. This operation is called by the client as and when required, so this has to be in the same transaction
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic