SHARE
TWEET

Untitled

a guest Jul 24th, 2019 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. LdapContextSource contextSource = new LdapContextSource();
  2. PoolingContextSource source = new PoolingContextSource();
  3.  
  4. contextSource.setUrl("The desired url");
  5. contextSource.setBase("");          
  6. contextSource.setUserDn("DN value");            contextSource.setPassword("Password");
  7. Map<String,Object> env = new HashMap<String,Object>();
  8. env.put("com.sun.jndi.ldap.connect.timeout", "15000");
  9. contextSource.setBaseEnvironmentProperties(env);                        contextSource.afterPropertiesSet();
  10.  
  11. source.setContextSource(contextSource);
  12. source.setMaxWait("Long value for 15000");
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top