[jboss-as7-dev] EJB 3 Proxies
David M. Lloyd
david.lloyd at redhat.com
Mon Jan 17 22:22:46 EST 2011
A question first. Is there ever a reason to bind a proxy (what you are
calling a "true proxy", I guess) directly into JNDI? It seems as though
binding an object factory would generally be the course of action, so
that if you look up a reference to some EJB but you're in a different
class loader, you get the proper instance. Am I right?
To answer your question, yes we will have probably not one but two
services per JNDI binding; but to put your heart at ease, a service in
MSC is much smaller, faster, and more predictable than a MC service.
We'll have to iron out the nitty gritty of bindings on interactive chat
though, there's too many fine details to hit them all by email (but
we'll be sure that the wiki pages are updated once all the facts are known).
On 01/17/2011 04:18 AM, Carlo de Wolf wrote:
> The goal is to provide the functionality as outlined in EJB 3.1 FR 4.3.3
> getBusinessObject and getEJB* methods, plus 4.4 Global JNDI Access.
>
> EJB Servitors provide an entry point InvocationDispatcher. Behind this
> entry point the local system interceptors are invoked. In essence an EJB
> Servitor is a 'singleton' ManagedBean
>
> For the purpose of JNDI the distinction is made between JNDI objects and
> true proxies. JNDI objects can be proxies, LinkRef or ObjectFactory. A
> true proxy is either a direct link or a lazy link to the servitor via
> its InvocationDispatcher interface.
>
> The JNDI names where the JNDI objects are bound are generated by an ejb3
> component. Who binds these objects is currently undecided.
> The generation of JNDI objects is delegated out of ejb3 to another
> construct.
>
> Within an EJB the user can call upon getBusinessObject for example. In
> this case a true proxy needs to be returned. Again ejb3 delegates out to
> another construct.
>
> Possibly the JNDI object and proxy factories can be co-located within
> one component.
>
> Note, there is a risk of overlap with remote invocation. Remote
> invocation is explicitly beyond scope of the EJB servitor dispatcher.
>
> Remote proxies are special InvocationDispatchers which can have client-
> and server side interceptors. The client side interceptors prepare for
> marshaling of the current invocation context (transaction, security
> etc). The server side interceptors transform the marshaled context into
> the local context equivalent.
>
> In short we need to design a way to bind the EJB views.
>
> Do we really need a service per JNDI binding (as per [1])?
>
> Carlo
>
> [1]
> http://community.jboss.org/wiki/JavaEEImplementationTechnicalRequirements
> _______________________________________________
> jboss-as7-dev mailing list
> jboss-as7-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jboss-as7-dev
--
- DML
More information about the jboss-as7-dev
mailing list