public class StandaloneLdapApiService
extends org.apache.directory.api.ldap.codec.osgi.DefaultLdapCodecService
LdapApiService implementation.
It loads the Controls and ExtendedOperations as defined in the following system parameters :
| Modifier and Type | Field and Description |
|---|---|
static String |
CONTROLS_LIST
The list of controls to load at startup
|
static String |
EXTENDED_OPERATIONS_LIST
The list of extended operations to load at startup
|
private static org.slf4j.Logger |
LOG
A logger
|
private static String |
OLD_DEFAULT_CONTROLS_LIST
The (old) list of default controls to load at startup
|
private static String |
OLD_EXTRA_EXTENDED_OPERATION_LIST
The (old) list of extra extended operations to load at startup
|
| Constructor and Description |
|---|
StandaloneLdapApiService()
Creates a new instance of StandaloneLdapCodecService.
|
StandaloneLdapApiService(List<String> controls,
List<String> extendedOperations)
Creates a new instance of StandaloneLdapApiService.
|
| Modifier and Type | Method and Description |
|---|---|
private static List<String> |
getControlsFromSystemProperties()
Parses the system properties to obtain the controls list.
|
private static List<String> |
getExtendedOperationsFromSystemProperties()
Parses the system properties to obtain the extended operations.
|
private void |
loadControl(String controlFQCN)
Loads a control from its FQCN.
|
private void |
loadControls(List<String> controlsList)
Loads a list of controls from their FQCN.
|
private void |
loadExtendedOperation(String extendedOperationFQCN)
Loads an of extended operations from its FQCN
|
private void |
loadExtendedOperations(List<String> extendedOperationsList)
Loads a list of extended operation from their FQCN
|
decorate, decorate, fromJndi, fromJndi, fromJndiControl, getControlFactories, getExtendedOperationsFactories, getProtocolCodecFactory, isControlRegistered, isExtendedOperationRegistered, newControl, newControl, newExtendedRequest, newExtendedResponse, newMessageContainer, registerControl, registeredControls, registeredExtendedRequests, registerExtendedRequest, registerProtocolCodecFactory, setControlFactories, setExtendedOperationsFactories, setProtocolCodecFactory, toJndi, toJndi, toJndiControl, unregisterControl, unregisterExtendedRequestprivate static final org.slf4j.Logger LOG
public static final String CONTROLS_LIST
public static final String EXTENDED_OPERATIONS_LIST
private static final String OLD_DEFAULT_CONTROLS_LIST
private static final String OLD_EXTRA_EXTENDED_OPERATION_LIST
public StandaloneLdapApiService()
throws Exception
<properties>
<codec.plugin.directory>${project.build.directory}/pluginDirectory</codec.plugin.directory>
</properties>
<build>
<plugins>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<groupId>org.apache.maven.plugins</groupId>
<configuration>
<systemPropertyVariables>
<workingDirectory>${basedir}/target</workingDirectory>
<felix.cache.rootdir>
${project.build.directory}
</felix.cache.rootdir>
<felix.cache.locking>
true
</felix.cache.locking>
<org.osgi.framework.storage.clean>
onFirstInit
</org.osgi.framework.storage.clean>
<org.osgi.framework.storage>
osgi-cache
</org.osgi.framework.storage>
<codec.plugin.directory>
${codec.plugin.directory}
</codec.plugin.directory>
</systemPropertyVariables>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>copy</id>
<phase>compile</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>${project.groupId}</groupId>
<artifactId>api-ldap-extras-codec</artifactId>
<version>${project.version}</version>
<outputDirectory>${codec.plugin.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
Exception - If we had an issue initializing the LDAP servicepublic StandaloneLdapApiService(List<String> controls, List<String> extendedOperations) throws Exception
controls - The list of controls to storeextendedOperations - The list of extended operations to storeException - If we had an issue with one of the two listsprivate static List<String> getControlsFromSystemProperties() throws Exception
Exceptionprivate static List<String> getExtendedOperationsFromSystemProperties() throws Exception
Exceptionprivate void loadControls(List<String> controlsList) throws Exception
Exceptionprivate void loadControl(String controlFQCN) throws Exception
Exceptionprivate void loadExtendedOperations(List<String> extendedOperationsList) throws Exception
ExceptionCopyright © 2003–2017 The Apache Software Foundation. All rights reserved.