On a side note, how is this addressed for EJB 1.1? Identity based methods
are now depricated, and WL support was not able to tell me how to change
what identity session beans run under (in WL 5.1)

-David

-----Original Message-----
From: A mailing list for Enterprise JavaBeans development
[mailto:[EMAIL PROTECTED]]On Behalf Of Rajan Kashyap
Sent: Monday, August 28, 2000 4:38 PM
To: [EMAIL PROTECTED]
Subject: Re: caller identity


Hi,
        Run your session bean as CLIENT_IDENTITY.
        set RunAsMode as CLIENT_IDENTITY in you DD.

Hope this helps,

Rajan


-----Original Message-----
From: A mailing list for Enterprise JavaBeans development
[mailto:[EMAIL PROTECTED]]On Behalf Of Ashwath Narayan
Sent: Monday, August 28, 2000 3:12 AM
To: [EMAIL PROTECTED]
Subject: caller identity


I am sorry if this topic was discussed before.

We are using WebLogic 4.5.1
All our database tables have a username field, which hold the name of the
person who created/updated the record.
When the user logs in, in the servlet I create the JNDI context object using
his username and password.

In the EJB, I extract the user's name using

        String username = sessionContext.getCallerIdentity().getName();
        or
        String username = entityContext.getCallerIdentity().getName();

( getCallerPrincipal() is not supported in WebLogic 4.5.1)

Assume I make a sessionbean call and session bean calles entitybeans.
I get the user's name right in the sessionbean.
But in the entitybean i get the user's name as "system".

Question: What is the way to get the actual user name in the entity bean
also?

Note: I create the JNDI context object in session bean using

        Context ctx = sessonContext.getEnvironment();

        I won't be able to create context object from scratch since I don't
have
the user's password when I am in sessionbean.

TIA
Ashwath

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to