Title: bind external LDAP context into jboss3.0 server JNDI context

Hi
I am new to this mail list and new to JBoss 3.0.

I am following the Jboss document for federating external LDAP into Jboss JNDI context using ExternalContext MBean. From JNDIView MBean, I can see the service=ExternalContext is registed under right jndiName in the DefaultDomain. But I can't see the external LDAP contents. Is something wrong already here?

I wrote a very simple bean and deployed into the jboss. The part of the code looks as following:
        DirContext iniCtx = new InitialDirContext();
            DirContext ldapCtx = (DirContext)iniCtx.lookup("external/ldap/iplanet");
        Attributes attrs = ldapCtx.getAttributes("uid=3Gold, ou=People");

When it executes getAttributes(), it throws "java.rmi.ServerException: Naming lookup failure: Not an instance of DirContext".

The attached is the ldap-service.xml for deploying external LDAP through ExternalContext MBean. One thing I am not sure in this file is the Properties attribute. I tried all values I can think of, such as file:///SAAS_Home/config/saas_ldap.properties, C:/SAAS_Home/config/saas_ldap.properties, c:\\SAAS_Home\\config\\saas_ldap.properties, file:/C:/SAAS_Home/config/saas_ldap.properties

 
I searched the jboss-user mailing by key words such as "DirContext", "LDAP", "naming lookup" and "ExternalContext" and etc. I could not find too much help. Any help will be greatly appreciated!

-Minsheng

Reply via email to