org.cougaar.core.thread |
This package contains the Cougaar
pooled {@link org.cougaar.core.service.ThreadService} implementation.
For most {@link org.cougaar.core.service.ThreadService} clients, the
only public APIs are the {@link org.cougaar.core.thread.Schedulable}
and perhaps {@link org.cougaar.core.thread.SchedulableStatus}.
{@link org.cougaar.core.service.ThreadService} documentation is in:
$COUGAAR_INSTALL_PATH/doc/OnlineManual/ThreadService/index.html
For more detail, see the
Cougaar Developers' Guide.
|
Java Source File Name | Type | Comment |
AgentControlPlugin.java | Class | This trivial Plugin exists only to create a
SchedulerWatcher for whatever Agent it's loaded in to. |
AgentLoadRatePlugin.java | Class | This Plugin collects the load history for the Agent in which it's
loaded, and uplaads that data to the metrics service. |
AgentLoadSensorPlugin.java | Class | This Plugin provides the
AgentLoadService for other Plugins
in the same Agent. |
AgentLoadService.java | Interface | This Service provides a simple time-based integral of agent load. |
CougaarThread.java | Interface | Defines a set of Schedulable state constants. |
DynamicSortedQueue.java | Class | A simple queue, built on array list, that uses a Comparator to
determine which elements is next (the smallest, according to the
Comparator). |
LimitThreadsPlugin.java | Class | This Component limits the number of threads that an agent can use
to run its schedulables in parallel. |
PercentageLoadSelector.java | Class | A sample
RightsSelector that attempts to select among the
children in such a way as to match a set of target percentages. |
PropagatingScheduler.java | Class | The standard hiearchical thread service implementation uses this
extension of
Scheduler to handle the propagation of rights. |
RightsPropagatingScheduler.java | Class | This experimenatal extension of
Scheduler is not currently used. |
RightsSelector.java | Interface | A getNextPending method of a RightSelector is used by a
PropagatingScheduler to decide now to share rights among its own
Schedulables and its children. |
RogueThreadDetector.java | Class | This plugin periodically scans all the schedulable and prints out
error messages if they are taking a long time to complete. |
RootControlPlugin.java | Class | This node-level Plugin shows examples of limiting the top-level
thread service in two ways: it sets the global max to 2, and it
qualifies rights selection for children so that no child ever uses
more than half of the available rights. |
RoundRobinSelector.java | Class | This is the standard implementation of
RightsSelector . |
RunnableQueue.java | Class | This utility class embads a
CircularQueue in its
own
Schedulable , the body of which processes elements on the queue
for up to 500ms or until the queue is empty, whichever comes
first. |
Schedulable.java | Interface | A Schedulable is an API provided by the
org.cougaar.core.service.ThreadService that takes the place
of standard Java
java.lang.Thread s and
java.util.TimerTask s.
Aside from a few special internal cases, all Threads and Tasks in
Cougaar should come from the ThreadService in the form of
Schedulables. |
SchedulableLifecyle.java | enum | |
SchedulableObject.java | Class | The standard implementation of
Schedulable . |
SchedulableStateChangeQueue.java | Class | |
SchedulableStatus.java | Class | An optional utility class for use by
java.lang.Runnable s
running in a pooled
org.cougaar.core.service.ThreadService thread to tell the
ThreadService why they are running
so long (for example, due to a blocking I/O call). |
Scheduler.java | Class | The base class of thread-scheduler. |
SchedulerWatcher.java | Class | This class listens for events on the closest ThreadService,
collects information about every consumer, and periodically uploads
that information the the metrics service. |
SerialSchedulable.java | Class | This is the
Schedulable implementation used by the simplest
thread service implementation, which runs its
Schedulable s
serially. |
SerialThreadQueue.java | Class | The simplest thread service implementation, which runs its
Schedulable s serially, uses this utility class to hold a set of
Schedulable s in proper sequence. |
SerialThreadRunner.java | Class | The simplest thread service implementation, which runs its
Schedulable s serially, uses a small Collection of
SerialThreadRunners to do that work. |
SingleThreadServiceProvider.java | Class | This Component provides a very simple, serializing
ThreadService for its container. |
SingleThreadServiceProxy.java | Class | The serializing trivial implementation of Thread Service. |
ThreadControlServiceProxy.java | Class | The implementation of
ThreadControlService . |
ThreadListener.java | Interface | Objects which wish to subscribe to the ThreadListenerService should
implement this interface. |
ThreadListenerProxy.java | Class | Implementation of
ThreadListenerService . |
ThreadPool.java | Class | A pool of native Java threads used by the standard implementation of the
ThreadService . |
ThreadServiceProvider.java | Class | This component is the
ServiceProvider for the
ThreadService ,
ThreadControlService ,
ThreadListenerService , and
ThreadStatusService . |
ThreadServiceProxy.java | Class | The default implementation of
ThreadService . |
ThreadStatusService.java | Interface | This service is designed to provide a low-fidelity snapshot of the
current state of the ThreadServices. |
ThreadsWellBehavedPlugin.java | Class | This class marks the agent as wellbehaved. |
TopPlugin.java | Class | This component is used to create the TopServlet, which it will do
unless the "servlet" parameter is set to "false", and the
RogueThreadDetector, which it will do unless the "detector"
parameter is set to "false".
The servlet displays a more or less current list of
Schedulable s, both running and queued, at all levels and for all
lanes, in a way that's vaguely remniscent of the unix 'top'
command. |
TopServlet.java | Class | This servlet displays a more or less current list of
Schedulable s, both running and queued, at all levels and for all
lanes, in a way that's vaguely remniscent of the unix 'top'
command. |
TreeNode.java | Class | This class is used to represent the hierarchy of the standard
layered
ThreadService . |
TrivialSchedulable.java | Class | This implementation of
Schedulable is used by the trivial
ThreadService , which has no queueing and always runs threads
immediately. |
TrivialThreadPool.java | Class | A simple pool of Java threads, used by the trivial
ThreadService . |
TrivialThreadServiceProvider.java | Class | The ServiceProvider for the simple
ThreadService s. |
TrivialThreadServiceProxy.java | Class | The trivial implementation of
ThreadService . |