Package org.opends.server.core
Class CoreConfigManager
java.lang.Object
org.opends.server.core.CoreConfigManager
- All Implemented Interfaces:
ConfigurationChangeListener<GlobalCfg>
Manages the set of core configuration attributes of the Directory Server.
These configuration attributes appear in the "cn=config" configuration entry.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceDefinition of a service providing etimes.static enumImplementation of services providing etimes. -
Constructor Summary
ConstructorsConstructorDescriptionCoreConfigManager(ServerContext serverContext) Creates a new instance of this core config manager. -
Method Summary
Modifier and TypeMethodDescriptionapplyConfigurationChange(GlobalCfg configuration) Applies the configuration changes to this change listener.voidcheckSubordinateDns(BackendConfigManager backendConfigManager) Checks for misconfiguration of subordinate base DNs: it emits a warning for each subordinate base DNs which do not have a corresponding backend.Retrieves a set containing the names of the allowed tasks that may be invoked in the server.Retrieves the DN of the configuration entry for the default password policy for the Directory Server.Returns aCoreConfigManager.EtimeServiceto compute processing time.com.forgerock.opendj.util.HostRetrieves the first advertised host for this server.Retrieves the group identifier of this server.longRetrieves the maximum number of connections that will be allowed at any given time.intReturns the threshold capacity beyond which internal cached buffers used for encoding and decoding entries and protocol messages will be trimmed after use.intRetrieves the maximum number of concurrent persistent searches that will be allowed.Retrieves the DNs of the configuration entry for the identity mappers that should be used in conjunction with proxied authorization V2 controls.Returns the server-configured resource limits.Retrieves the identifier of this server.Retrieves the policy that should be used regarding enforcement of a single structural object class per entry.Retrieves the restricted set of subordinate base DNs to use when searching the root suffix "".Retrieves the policy that should be used when an attribute value is found that is not valid according to the associated attribute syntax.Indicates how unauthenticated requests should be handled by the server.Retrieves the writability mode for the Directory Server.booleanIndicates whether the Directory Server should automatically add missing RDN attributes to an entry whenever it is added.booleanIndicates whether simple bind requests that contain a bind DN will also be required to have a password.booleanIndicates whether the Directory Server should perform schema checking.booleanisConfigurationChangeAcceptable(GlobalCfg configuration, List<LocalizableMessage> unacceptableReasons) Indicates whether the proposed change to the configuration is acceptable to this change listener.booleanisDisabled(Privilege privilege) Indicates whether the specified privilege is disabled.booleanIndicates whether the Directory Server should send a response to an operation that has been abandoned.booleanIndicates whether responses to failed bind operations should include a message explaining the reason for the failure.booleanIndicates whether configuration should be saved on successful startup of the server.Returns the default schema validation policy that should be used by the server.booleanIndicates if transaction IDs received from requests should be trusted and logged.
-
Constructor Details
-
CoreConfigManager
Creates a new instance of this core config manager.- Parameters:
serverContext- The server context.
-
-
Method Details
-
isConfigurationChangeAcceptable
public boolean isConfigurationChangeAcceptable(GlobalCfg configuration, List<LocalizableMessage> unacceptableReasons) Description copied from interface:ConfigurationChangeListenerIndicates whether the proposed change to the configuration is acceptable to this change listener.- Specified by:
isConfigurationChangeAcceptablein interfaceConfigurationChangeListener<GlobalCfg>- Parameters:
configuration- The new configuration containing the changes.unacceptableReasons- A list that can be used to hold messages about why the provided configuration is not acceptable.- Returns:
- Returns
trueif the proposed change is acceptable, orfalseif it is not.
-
checkSubordinateDns
Checks for misconfiguration of subordinate base DNs: it emits a warning for each subordinate base DNs which do not have a corresponding backend.- Parameters:
backendConfigManager- the backend config manager
-
applyConfigurationChange
Description copied from interface:ConfigurationChangeListenerApplies the configuration changes to this change listener.- Specified by:
applyConfigurationChangein interfaceConfigurationChangeListener<GlobalCfg>- Parameters:
configuration- The new configuration containing the changes.- Returns:
- Returns information about the result of changing the configuration.
-
getAllowedTasks
Retrieves a set containing the names of the allowed tasks that may be invoked in the server.- Returns:
- A set containing the names of the allowed tasks that may be invoked in the server.
-
getDefaultPasswordPolicyDN
Retrieves the DN of the configuration entry for the default password policy for the Directory Server.- Returns:
- The DN of the configuration entry for the default password policy for the Directory Server.
-
getMaxAllowedConnections
public long getMaxAllowedConnections()Retrieves the maximum number of connections that will be allowed at any given time.- Returns:
- the max number of connections allowed
-
getMaxInternalBufferSize
public int getMaxInternalBufferSize()Returns the threshold capacity beyond which internal cached buffers used for encoding and decoding entries and protocol messages will be trimmed after use.- Returns:
- The threshold capacity beyond which internal cached buffers used for encoding and decoding entries and protocol messages will be trimmed after use.
-
getMaxPSearches
public int getMaxPSearches()Retrieves the maximum number of concurrent persistent searches that will be allowed.- Returns:
- the max number of persistent searches
-
getProxiedAuthorizationIdentityMapperDNs
Retrieves the DNs of the configuration entry for the identity mappers that should be used in conjunction with proxied authorization V2 controls.- Returns:
- The DNs of the configuration entry for the identity mappers that should be used in conjunction with proxied authorization V2 controls, or an empty set if none is defined.
-
getServerId
Retrieves the identifier of this server.- Returns:
- the server id
-
getGroupId
Retrieves the group identifier of this server.- Returns:
- the group id
-
getFirstAdvertisedHost
public com.forgerock.opendj.util.Host getFirstAdvertisedHost()Retrieves the first advertised host for this server.- Returns:
- the first advertised host for this server.
-
getSingleStructuralObjectClassPolicy
Retrieves the policy that should be used regarding enforcement of a single structural object class per entry.- Returns:
- The policy that should be used regarding enforcement of a single structural object class per entry.
-
serverPolicy
Returns the default schema validation policy that should be used by the server.- Returns:
- the default schema validation policy that should be used by the server.
-
getSubordinateBaseDNs
Retrieves the restricted set of subordinate base DNs to use when searching the root suffix "".- Returns:
- the subordinate base DNs, which is empty if there is no restriction
-
getSyntaxEnforcementPolicy
Retrieves the policy that should be used when an attribute value is found that is not valid according to the associated attribute syntax.- Returns:
- The policy that should be used when an attribute value is found that is not valid according to the associated attribute syntax.
-
getResourceLimits
Returns the server-configured resource limits.- Returns:
- the server-configured resource limits
-
getEtimeService
Returns aCoreConfigManager.EtimeServiceto compute processing time.- Returns:
- a
CoreConfigManager.EtimeServiceto compute processing time.
-
getWritabilityMode
Retrieves the writability mode for the Directory Server. This will only be applicable for user suffixes.- Returns:
- The writability mode for the Directory Server.
-
isAddMissingRDNAttributes
public boolean isAddMissingRDNAttributes()Indicates whether the Directory Server should automatically add missing RDN attributes to an entry whenever it is added.- Returns:
trueif the Directory Server should automatically add missing RDN attributes to an entry, orfalseif it should return an error to the client.
-
isBindWithDNRequiresPassword
public boolean isBindWithDNRequiresPassword()Indicates whether simple bind requests that contain a bind DN will also be required to have a password.- Returns:
trueif simple bind requests containing a bind DN will be required to have a password, orfalseif not (and therefore will be treated as anonymous binds).
-
isCheckSchema
public boolean isCheckSchema()Indicates whether the Directory Server should perform schema checking.- Returns:
trueif the Directory Server should perform schema checking, orfalseif not.
-
isDisabled
Indicates whether the specified privilege is disabled.- Parameters:
privilege- The privilege for which to make the determination.- Returns:
trueif the specified privilege is disabled, orfalseif not.
-
isNotifyAbandonedOperations
public boolean isNotifyAbandonedOperations()Indicates whether the Directory Server should send a response to an operation that has been abandoned. Sending such a response is technically a violation of the LDAP protocol specification, but not doing so in that case can cause problems with clients that are expecting a response and may hang until they get one.- Returns:
trueif the Directory Server should send a response to an operation that has been abandoned, orfalseif not.
-
getUnauthenticatedRequestsPolicy
Indicates how unauthenticated requests should be handled by the server.- Returns:
- The policy specifying how unauthenticated requests should be handled by the server.
-
isReturnBindErrorMessages
public boolean isReturnBindErrorMessages()Indicates whether responses to failed bind operations should include a message explaining the reason for the failure.- Returns:
trueif bind responses should include error messages, orfalseif not.
-
isSaveConfigOnSuccessfulStartup
public boolean isSaveConfigOnSuccessfulStartup()Indicates whether configuration should be saved on successful startup of the server.- Returns:
trueif configuration should be saved,falseotherwise.
-
shouldTrustTransactionIds
public boolean shouldTrustTransactionIds()Indicates if transaction IDs received from requests should be trusted and logged. If set totrue, the server will add a transaction ID control to all the requests which do not already include one, and the server will add a sub-transaction ID control to all the forwarded requests. If set tofalse, the server will discard all incoming transaction IDs and create new ones.- Returns:
trueif transactionIds should be trusted,falseotherwise
-