|
Foundation |
|
| |||||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
See:
Description
Class Summary | |
---|---|
JNDIConnectionFactoryConfiguration | A connection factory configuration that describes a server or a pool of servers to connect to using meta data in accessed through a JNDI interface. |
JNDI connection services.
If the metadata defines a connection pool, then the two-tiered security model dictates that the metadata repository be used authenticate factory users. You may provide an authentication domain name for the ldap server, and the connection factory will include this name in it's list of valid authentication domains if it is configured for pooling. If you do not provide a name, and empty string will be used, if necessary.
The following code fragment demonstrates connection factory configuration using JNDI metadata.
Hashtable env = new Hashtable(); env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory"); env.put(Context.PROVIDER_URL,"ldap://ldap.abc.com:389"); env.put(Context.SECURITY_AUTHENTICATION,"simple"); env.put(Context.SECURITY_PRINCIPAL,"cn=admin,o=ABC,c=US"); env.put(Context.SECURITY_CREDENTIALS,"admin1"); DirContext ctx = new InitialDirContext(env); String searchContext = "o=ABC,c=US"; String logicalName = "myServer"; String ldapServerDomain = "LDAP"; ConnectionFactoryConfiguration cxfConfig = new JNDIConnectionFactoryConfiguration(ctx,searchContext,logicalName,ldapServerDomain); |
|
Foundation |
|
| |||||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |