| | |
| | | import java.util.concurrent.TimeUnit; |
| | | |
| | | import org.opends.server.admin.std.server.MonitorProviderCfg; |
| | | import org.opends.server.api.AttributeSyntax; |
| | | import org.forgerock.opendj.ldap.schema.Syntax; |
| | | import org.opends.server.api.MonitorProvider; |
| | | import org.forgerock.opendj.config.server.ConfigException; |
| | | import org.opends.server.core.DirectoryServer; |
| | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void initializeMonitorProvider(MonitorProviderCfg configuration) |
| | | throws ConfigException, InitializationException |
| | | { |
| | |
| | | * |
| | | * @return The name of this monitor provider. |
| | | */ |
| | | @Override |
| | | public String getMonitorInstanceName() |
| | | { |
| | | return "Work Queue"; |
| | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void run() |
| | | { |
| | | int backlog = workQueue.size(); |
| | |
| | | * returned to the client if the corresponding monitor entry is |
| | | * requested. |
| | | */ |
| | | @Override |
| | | public ArrayList<Attribute> getMonitorData() |
| | | { |
| | | int backlog = workQueue.size(); |
| | |
| | | long rejectedQueueFull = workQueue.getOpsRejectedDueToQueueFull(); |
| | | |
| | | ArrayList<Attribute> monitorAttrs = new ArrayList<Attribute>(); |
| | | AttributeSyntax<?> integerSyntax = DirectoryServer |
| | | .getDefaultIntegerSyntax(); |
| | | Syntax integerSyntax = DirectoryServer.getDefaultIntegerSyntax(); |
| | | |
| | | // The current backlog. |
| | | AttributeType attrType = DirectoryServer.getDefaultAttributeType( |