• 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:
  • Tim Cooke
  • Campbell Ritchie
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

interesting.

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
afterCompletion() has a clent security context . So , eventhough it doesnt have a transaction context , it should be able to accesss resource mgr and beans . but the specification(on pg 80) says not so!! please check this
 
Ranch Hand
Posts: 775
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is no meaningful transaction context, hence no access to a resource manager. Resource managers always have a transaction context of some sort. Spec page 81.
 
Ramakrishna Allam
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Infact page 81 of the spec says that "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."
For ex , even ejbCreate() , ejbRemove(),ejbActivate() and ejbPassivate() methods of SFSB will be in unspecified transactional context . But they can access resource mgrs and other Enterprise beans because they have a security context attached with them . Its the same case with afterCompletion . ie.Though this doesnt have a transactional context , it has a security context (for ex , it can call getCallerPrincipal and isCallerInRole(String roleName)) . But i do not really understand why this afterCompletion(boolean isCommitted) can not access resource mgrs and other beans while ejbCreate() etc can access ...Please Clarify .
reply
    Bookmark Topic Watch Topic
  • New Topic