Krish,

This is something that has bugged me, also.  It also bugs me when people
load up their InitialContext constructors with hashtables, when the spec
guarantees that a no-arg constructor must return the correct Context for
finding the ENC.

I'd heard rumors that in later versions of the spec, the idea of a global
JNDI namespace for anything but remote EJBs (which have to be visible in
COSNaming) might be explicitly forbidden.

A couple questions for you:
1. You said that an ENC lookup must always be in-process.  Is that mandated
by the spec?  I don't recall ever hearing that before.

2. I've always wondered whether app server vendors can put little
optimization hooks into ENC calls that they can't do with global JNDI
lookups.  Do you do anything special?

Ken DeLong
[EMAIL PROTECTED]


> Date:    Fri, 28 Feb 2003 11:54:52 +0100
> From:    Krishnan Subramanian <[EMAIL PROTECTED]>
> Subject: how not to look up local Ejbs
>
> All,
>
> Many EJB developers who are building applications based on
> the EJB 2.x specification seem to be making this (serious)
> mistake; and worse do not realize that their code is relying
> on an AppServer bug.
>
> The problem itself is a simple one:
>
> When looking up an EJB with local interfaces, developers use
> the physical JNDI name of the local enterprise bean in lieu
> of the specification defined environment naming context(ENC).
<snip>

===========================================================================
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