EJBContext for HelperClass

O

Ole Laurisch

Hello everybody,

I have an application with several session (and entity) beans. Moreover
there are some helper classes, which are no EJBs, but are accessed by them.
In one of these helper classes I need to know the principal of the ejb that
is invoking the helper class. Therefore I need access to the EJBContext
object to call the getCallerPrincipal() method.

Now my question:
How do I get the EJBContext? Do I have to pass it from the EJB-method or is
there any way to get it from the helper class?
The benefit would be, that the developers of the EJBs don't have to think
about passing the EJB-Context.

Many thanks in advance,

Ole
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,677
Members
48,796
Latest member
Greg L.

Latest Threads

Top