@InterfaceAudience.Private public class TaskMonitor extends Object
Modifier and Type | Class and Description |
---|---|
private static class |
TaskMonitor.PassthroughInvocationHandler<T>
An InvocationHandler that simply passes through calls to the original
object.
|
private static class |
TaskMonitor.TaskAndWeakRefPair
This class encapsulates an object as well as a weak reference to a proxy
that passes through calls to that object.
|
Modifier and Type | Field and Description |
---|---|
private static long |
EXPIRATION_TIME |
private static TaskMonitor |
instance |
private static org.apache.commons.logging.Log |
LOG |
(package private) static int |
MAX_TASKS |
private org.apache.commons.collections.buffer.CircularFifoBuffer |
tasks |
Constructor and Description |
---|
TaskMonitor() |
Modifier and Type | Method and Description |
---|---|
private boolean |
canPurge(MonitoredTask stat) |
MonitoredRPCHandler |
createRPCStatus(String description) |
MonitoredTask |
createStatus(String description) |
void |
dumpAsText(PrintWriter out) |
static TaskMonitor |
get()
Get singleton instance.
|
List<MonitoredTask> |
getTasks()
Produces a list containing copies of the current state of all non-expired
MonitoredTasks handled by this TaskMonitor.
|
private void |
purgeExpiredTasks() |
private static final org.apache.commons.logging.Log LOG
private static final long EXPIRATION_TIME
static final int MAX_TASKS
private static TaskMonitor instance
private org.apache.commons.collections.buffer.CircularFifoBuffer tasks
public static TaskMonitor get()
public MonitoredTask createStatus(String description)
public MonitoredRPCHandler createRPCStatus(String description)
private void purgeExpiredTasks()
public List<MonitoredTask> getTasks()
private boolean canPurge(MonitoredTask stat)
public void dumpAsText(PrintWriter out)
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.