C
- the type of the BackendCfg for the current backendpublic abstract class Backend<C extends Configuration> extends Object implements RequestHandler, HealthStatusProvider
Constructor and Description |
---|
Backend() |
Modifier and Type | Method and Description |
---|---|
abstract void |
configureBackend(C cfg,
ServerContext serverContext)
Configure this backend based on the information in the provided configuration.
|
void |
deregisterBackendMonitor()
Deregisters the backend monitor of this backend.
|
abstract void |
finalizeBackend()
Performs any necessary work to finalize this backend.
|
String |
getBackendID()
Retrieves the unique identifier for this backend.
|
abstract Set<Dn> |
getBaseDNs()
Retrieves the set of base-level DNs that may be used within this backend.
|
HealthStatus |
getHealthStatus()
Returns the
HealthStatus for the underlying component. |
Set<String> |
getSupportedControls()
Retrieves the OIDs of the controls that may be supported by this backend.
|
Set<String> |
getSupportedFeatures()
Retrieves the OIDs of the features that may be supported by this backend.
|
boolean |
isConfigurationAcceptable(C configuration,
List<LocalizableMessage> unacceptableReasons,
ServerContext serverContext)
Indicates whether the provided configuration is acceptable for this backend.
|
abstract boolean |
isPublicBackend()
Indicates whether the base DNs of this backend should be considered public or private.
|
abstract void |
openBackend()
Opens this backend based on the information provided when the backend was configured.
|
void |
registerBackendMonitor()
Registers a backend monitor for this backend.
|
void |
setBackendID(String backendID)
Specifies the unique identifier for this backend.
|
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
handle
public abstract void configureBackend(C cfg, ServerContext serverContext) throws ConfigException
cfg
- The configuration of this backend.serverContext
- The server context for this instanceConfigException
- If there is an error in the configuration.public abstract void openBackend() throws ConfigException, InitializationException
ConfigException
- If an unrecoverable problem arises while opening the backend.InitializationException
- If a problem occurs during opening that is not related to the server configuration.configureBackend(C, org.opends.server.core.ServerContext)
public abstract void finalizeBackend()
configureBackend()
has been called. This may be called during the
Directory Server shutdown process or if a backend is disabled with the server online. It must not return until
the backend is closed.
This method may not throw any exceptions. If any problems are encountered, then they may be logged but the closure should progress as completely as possible.
public final String getBackendID()
public abstract Set<Dn> getBaseDNs()
public Set<String> getSupportedControls()
public Set<String> getSupportedFeatures()
public boolean isConfigurationAcceptable(C configuration, List<LocalizableMessage> unacceptableReasons, ServerContext serverContext)
configuration
- The backend configuration for which to make the determination.unacceptableReasons
- A list that may be used to hold the reasons that the provided configuration is not acceptable.serverContext
- this Directory Server instance's server contexttrue
if the provided configuration is acceptable for this backend, or false
if not.public abstract boolean isPublicBackend()
This method also controls the visibility of the associated naming contexts. i.e. if any base DN of this backend is a naming context, then it will be public or private, based on the value returned by this method.
Reminder: Public naming contexts are returned when querying the root DSE entry.
true
if this backend's baseDNs could be exposed as a public naming context, false
if they
must remain private naming contexts.public final void setBackendID(String backendID)
backendID
- The unique identifier for this backend.public void registerBackendMonitor()
public void deregisterBackendMonitor()
public HealthStatus getHealthStatus()
HealthStatusProvider
HealthStatus
for the underlying component.getHealthStatus
in interface HealthStatusProvider
HealthStatus
.Copyright 2010-2022 ForgeRock AS.