This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
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

How unspacified Txn have access to resources

 
sandeep vaid
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In spacification page 80. the table is given in case of stateful session bean.

In that table it is shown that

ejbCreate()
ejbRemove()
ejbPassicate()
ejbActivate()

can have:

access to Resource Managers
access to Enterprise Beans

How these methods access these when they run under unsapcifed context when CMT is used ???

Ok in case of BMT we can access if we begin our transaction with UserTransaction which is allowed in these methods !!!




Thanks !!!
Sandy
 
sandeep vaid
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok regarding this i got one answer so let me tell u if it is wrong

� Accessing resource managers and enterprise beans is disallowed in the session bean methods for which the Container does not have a meaningful transaction context or client security context.transaction context or client security context.

so we have proper client security context.

Thanks ! ! !
Sandy
 
James Turner
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think that the main requirement is a client security context rather then a transaction context. This is because other EJB's and resources need to know if they can grant access to their methods or not, therefore client security context is needed. Some methods and resources may not want to run in a transaction, i.e. NotSupported, Never; therefore, transaction contexts may not always be necessary.

Basically, from my point of view: To access another EJB or resource we must always have a client security context, but not necessarily a transaction context.

Regards,

James.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic