is an interface, an the implementation may provide many advanced
features. The default Monitor implementation is built as a
composite : it uses a set of sub-components to compute
indicators about the application state.
Those components MUST implement the interface
). Before being used by the composite monitor, they receive the
composite via the
initialization method. This method will be called any time a new
aggregator is added or removed to the monitor. The aggregator
may use the composite to acces other aggregators.
Each aggregator receives datas from the composite monitor in the
method. They can use this data to compute any indicator or run
any process that can be usefull to monitor the application
method is used to reset the aggregator from a management
console. Be aware that some counters may not be set to null in
this method : for example, the
aggregator manages a counter of concurrent active threads that
use the monitor. Also be aware when creating custom aggreagtors
that they are used in a concurrent context. synchronize the
required methods or use
classes to assume thread-safety and data consistency.
Custom aggregators are managed by a
implementation (see later section about features). The
default-one uses a properties files in classpath root :
. This file lists class name of Factories used to create the
aggregators instances. The factory (
) is used by jMonit to create new aggregators instance for
monitors on demand.