[jboss-dev] Accessing java: namespace from outside the server JVM (keeping in mind EJB3.1 spec)

Jaikiran Pai jpai at redhat.com
Tue Nov 2 08:10:33 EDT 2010


Traditionally JBoss AS (backed by the JNP naming server) hasn't allowed 
access to objects bound in java: JNDI namespace outside of the server 
JVM. For example, if someone does a java:DefaultDS lookup from a remote 
JVM, it's bound to fail with a NameNotFoundException. However, with the 
introduction of "Global JNDI naming scheme" in EJB3.1 spec, which 
mandates binding of EJBs under the java:global/ namespace, accessing the 
beans under java:global/ namespace from outside server JVM becomes 
necessary.

 From what I understand, the java: namespace handling (i.e. not allowing 
it to be accessed outside the JVM) is a JBoss specific implementation 
detail and the spec doesn't mandate that (haven't found a documentation 
which says otherwise).

Is there a way, we can make available the resources under java: 
namespace to be available to remote clients, in AS6? I understand that 
this might break existing functionality and applications, so probably we 
could pass a property through the InitialContext constructor (or 
jndi.properties) during a EJB lookup (or any other lookup for that 
matter) which would explicitly allow access to this namespace remotely. 
Is this something that could be introduced in the naming server 
implementation? Or any other better way to handle this?


P.S: Looking at the naming server code, I _think_ I might have a very 
hackish way of providing a remotely accessible java:global/ namespace, 
from  within the EJB3 jndi binding code. I haven't tried it though and 
would preferably avoid doing it in the EJB3 code.


-Jaikiran
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-development/attachments/20101102/dd536176/attachment.html 


More information about the jboss-development mailing list