Class ContextConfigurationContextSettings
java.lang.Object
io.micronaut.security.ldap.context.ContextConfigurationContextSettings
- All Implemented Interfaces:
ContextSettings
Implementation of
ContextSettings that derives its values from
an instance of LdapConfiguration.- Since:
- 1.0
- Author:
- James Kleeh
-
Constructor Summary
ConstructorsConstructorDescriptionContextConfigurationContextSettings(LdapConfiguration configuration) Settings for the manager context.ContextConfigurationContextSettings(LdapConfiguration configuration, String dn, String password) Settings for a context bound with user credentials. -
Method Summary
-
Constructor Details
-
ContextConfigurationContextSettings
Settings for the manager context. The context is pooled only ifLdapConfiguration.ContextConfiguration.isPooled()istrue.- Parameters:
configuration- The ldap configuration
-
ContextConfigurationContextSettings
public ContextConfigurationContextSettings(LdapConfiguration configuration, String dn, String password) Settings for a context bound with user credentials. Such a context is never pooled.- Parameters:
configuration- The ldap configurationdn- The user DN to bind withpassword- The password to bind with
-
-
Method Details
-
getPooled
public boolean getPooled()- Specified by:
getPooledin interfaceContextSettings- Returns:
- True if the context should be pooled
-
getFactory
- Specified by:
getFactoryin interfaceContextSettings- Returns:
- The factory class
-
getUrl
- Specified by:
getUrlin interfaceContextSettings- Returns:
- The URL of the LDAP server
-
getDn
- Specified by:
getDnin interfaceContextSettings- Returns:
- The user DN to bind with
-
getPassword
- Specified by:
getPasswordin interfaceContextSettings- Returns:
- The password to bind with
-
getAdditionalProperties
The additional properties of the configuration. For the pooled manager context they also carry thecom.sun.jndi.ldap.connect.timeoutJNDI environment property derived fromLdapConfiguration.ContextConfiguration.PoolConfiguration.getConnectTimeout(), unless the configured properties already set it, so that a login does not wait indefinitely when the pool is saturated.- Specified by:
getAdditionalPropertiesin interfaceContextSettings- Returns:
- The additional properties
-