T
- The type of configuration handled by this monitor provider.@PublicAPI(stability=VOLATILE, mayExtend=true) public abstract class MonitorProvider<T extends org.forgerock.opendj.server.config.server.MonitorProviderCfg> extends Object
Constructor and Description |
---|
MonitorProvider() |
Modifier and Type | Method and Description |
---|---|
void |
finalizeMonitorProvider()
Finalizes this monitor provider so that it may be unloaded and taken out of service.
|
abstract MonitorData |
getMonitorData()
Retrieves a set of attributes containing monitor data that should be returned to the client if the corresponding
monitor entry is requested.
|
org.forgerock.opendj.ldap.Dn |
getMonitorInstanceDn()
Returns the DN of this monitor provider.
|
String |
getMonitorInstanceName()
Retrieves the name of this monitor provider.
|
org.forgerock.opendj.ldap.schema.ObjectClass |
getMonitorObjectClass()
Retrieves the objectclass that should be included in the monitor entry created from this monitor provider.
|
void |
initializeMonitorProvider(T configuration)
Initializes this monitor provider based on the information in the provided configuration entry.
|
boolean |
isConfigurationAcceptable(T configuration,
List<LocalizableMessage> unacceptableReasons)
Indicates whether the provided configuration is acceptable for this monitor provider.
|
protected void |
scheduleUpdate(Runnable updater,
long initialDelay,
long period,
TimeUnit unit)
Schedules any periodic processing that may be desired to update the information associated with this monitor.
|
public void initializeMonitorProvider(T configuration) throws org.forgerock.opendj.config.server.ConfigException, InitializationException
configuration
- The configuration to use to initialize this monitor provider.org.forgerock.opendj.config.server.ConfigException
- If an unrecoverable problem arises in the process of performing the initialization.InitializationException
- If a problem occurs during initialization that is not related to the server configuration.public boolean isConfigurationAcceptable(T configuration, List<LocalizableMessage> unacceptableReasons)
configuration
- The monitor provider 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.true
if the provided configuration is acceptable for this monitor provider, or false
if
not.public void finalizeMonitorProvider()
super.finalizeMonitorProvider
.public org.forgerock.opendj.ldap.Dn getMonitorInstanceDn()
getMonitorInstanceName()
.public String getMonitorInstanceName()
UnsupportedOperationException
indicating that neither this method nor getMonitorInstanceDn()
have been
overridden.UnsupportedOperationException
- If neither this method nor getMonitorInstanceDn()
have been overridden.public org.forgerock.opendj.ldap.schema.ObjectClass getMonitorObjectClass()
protected final void scheduleUpdate(Runnable updater, long initialDelay, long period, TimeUnit unit)
getUpdateInterval
milliseconds apart, but no guarantees will be made.updater
- The updater to execute.initialDelay
- The time to delay first execution.period
- The period between successive executions.unit
- The time unit of the initialDelay and period parameters.public abstract MonitorData getMonitorData()
Copyright © 2010–2017 ForgeRock AS. All rights reserved.