• Post Reply Bookmark Topic Watch Topic
  • New Topic

Why CMT SFSB ejbCreate can access other bean ?

 
Vince Hon
Ranch Hand
Posts: 117
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
in HFB p.671, question 12

Given a stateful session bean with container-managed transaction demarcation, from which methods can you access another bean ? (Choose all that apply).

A. setSessionContext()
B. ejbCreate()
C. afterBegin()
D. beforeCompletion()
E. afterCompletion()

The ans is B,C,D.

I don't know why "B" is correct, since we cannot apply transaction attribute on ejbCreate(), there should be "no meaningful tx context" why ejbCreate() can access another beans ?


Thanks ~
 
Kris Reid
Ranch Hand
Posts: 247
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That is the same question I just posted
I totally agree with you
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!