|
Hyperic HQ Plugin API v. 4.4.0.2 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.hyperic.hq.product.GenericPlugin
org.hyperic.hq.product.MeasurementPlugin
public class MeasurementPlugin
Define and collect metrics.
| Field Summary | |
|---|---|
static java.lang.String |
PROP_TEMPLATE_CONFIG
|
static java.lang.String |
TYPE_COLLECTOR
|
| Fields inherited from class org.hyperic.hq.product.GenericPlugin |
|---|
config, FILE_DELIM, FILE_DELIM_ESC, PROP_NAME |
| Constructor Summary | |
|---|---|
MeasurementPlugin()
|
|
| Method Summary | |
|---|---|
java.util.Properties |
getCollectorProperties(Metric metric)
|
ConfigSchema |
getConfigSchema(TypeInfo info,
ConfigResponse config)
The ConfigSchema used to render config options for this resource in the UI and client shell. |
java.lang.String |
getHelp(TypeInfo info,
java.util.Map props)
|
protected MeasurementPluginManager |
getManager()
|
protected java.util.Map |
getMeasurementProperties()
Allow xml template properties to be added by a plugin. |
MeasurementInfo[] |
getMeasurements(TypeInfo info)
|
Collector |
getNewCollector()
|
protected java.lang.String[][] |
getPlatformHelpProperties()
|
protected java.lang.String |
getPluginXMLHelp(TypeInfo info,
java.lang.String name,
java.util.Map props)
|
MetricValue |
getValue(Metric metric)
This method is called when the plugin is asked for a metric value. |
void |
init(PluginManager manager)
Called when the plugin is loaded on the server and on the agent side. |
java.lang.String |
translate(java.lang.String template,
ConfigResponse config)
Translate a measurement as returned from getMeasurements() into a value which can be passed into the plugin's getValue() routine. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String PROP_TEMPLATE_CONFIG
public static final java.lang.String TYPE_COLLECTOR
| Constructor Detail |
|---|
public MeasurementPlugin()
| Method Detail |
|---|
public void init(PluginManager manager)
throws PluginException
GenericPlugin
init in class GenericPluginmanager - The plugin manager for this plugin type.
PluginExceptionprotected MeasurementPluginManager getManager()
protected java.util.Map getMeasurementProperties()
public MeasurementInfo[] getMeasurements(TypeInfo info)
protected java.lang.String[][] getPlatformHelpProperties()
protected java.lang.String getPluginXMLHelp(TypeInfo info,
java.lang.String name,
java.util.Map props)
public java.lang.String getHelp(TypeInfo info,
java.util.Map props)
public MetricValue getValue(Metric metric)
throws PluginException,
MetricNotFoundException,
MetricUnreachableException
metric - Value returned from translate(), representing a
specific metric to retrieve
MetricInvalidException - The plugin is unable to use the metric,
generally a developer bug where the template is malformed.
I.e. JMX MalformedObjectNameException
MetricNotFoundException - The monitored resource does not know
about the requested Metric. I.e. JMX AttributeNotFoundException
MetricUnreachableException - The monitored resource is unreachable.
I.e. ConnectException
PluginException - Thrown when an internal plugin error occurspublic Collector getNewCollector()
public java.util.Properties getCollectorProperties(Metric metric)
public java.lang.String translate(java.lang.String template,
ConfigResponse config)
template - Measurement template from one of the plugins
measurements returned from getMeasurements()config - Configuration used to perform translation on the
template
PluginException - When an internal plugin error occurs
MetricInvalidException - When the template passed cannot
be mapped to a template returned
via getMeasurements()
public ConfigSchema getConfigSchema(TypeInfo info,
ConfigResponse config)
GenericPlugin
getConfigSchema in class GenericPlugininfo - The TypeInfo of this plugin from ProductPlugin.getTypesconfig - ConfigReponse of the parent resource (if any).
|
Hyperic HQ Plugin API v. 4.4.0.2 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||