If you're writing from that domain you should know ;-)

I think that the spec prohibits _concurrent_ access from different
threads, not holding references to a bean.

To be able to handle concurrent calls from different threads would make
coding of session beans(and/or the containers that host them) a lot more
difficult than it is, as the session bean would need to be able to track
different transactional contexts and be reentrant.

It doesn't make much sense to store a SL SessionBean instance except to
spare the lookup of the Home instance and creation process; I'm pretty
much intrigued if someone could come up with a reason to get a handle to
a SLSB.

As for SFSBs, well, it's pretty obvious why...


Juan Pablo Lorandi
Chief Software Architect
Code Foundry Ltd.
[EMAIL PROTECTED]

Barberstown, Straffan, Co. Kildare, Ireland.
Tel: +353-1-6012050  Fax: +353-1-6012051
Mobile: +353-86-2157900
www.codefoundry.com


> -----Original Message-----
> From: A mailing list for Enterprise JavaBeans development
> [mailto:[EMAIL PROTECTED]] On Behalf Of Kenneth D. Litwak
> Sent: Wednesday, July 17, 2002 6:58 PM
> To: [EMAIL PROTECTED]
> Subject: Handles and threads
>
>
>    According to the spec, it is illegal for two client
> threads to access the same session bean instance.  So let/'s
> say I get a handle to my bean instance (not a home handle).
> I cannot give this handle to another client because it is
> illegal for two clients to access the same session bean
> instance.  I already have a reference to the bean's EJBObject
> before I get a handle.  So hat good is the handle?  Thanks.
>
>
>    Ken
>
> ==============================================================
> =============
> 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