public abstract class AbstractMetric extends Object
Modifier and Type | Field and Description |
---|---|
protected String |
baseQueueName |
protected hudson.model.AbstractBuild<?,?> |
build |
protected GraphiteLogger |
graphiteLogger |
protected PrintStream |
logger |
protected GraphiteValidator |
validator |
Constructor and Description |
---|
AbstractMetric(hudson.model.AbstractBuild<?,?> build,
PrintStream logger,
GraphiteLogger graphiteLogger,
String baseQueueName) |
Modifier and Type | Method and Description |
---|---|
protected String |
getCheckedBaseQueueName()
Check if base queuename is null or whitespace and return empty, otherwise return the base queue name with a full stop appended
|
abstract void |
sendMetric(Server server,
Metric... metric) |
protected void |
sendMetric(Server server,
Metric metric,
String value) |
protected GraphiteValidator validator
protected final hudson.model.AbstractBuild<?,?> build
protected final PrintStream logger
protected final GraphiteLogger graphiteLogger
protected final String baseQueueName
public AbstractMetric(hudson.model.AbstractBuild<?,?> build, PrintStream logger, GraphiteLogger graphiteLogger, String baseQueueName)
build
- logger
- graphiteLogger
- protected void sendMetric(Server server, Metric metric, String value) throws UnknownHostException, IOException
server
- metric
- value
- UnknownHostException
IOException
protected String getCheckedBaseQueueName()
public abstract void sendMetric(Server server, Metric... metric) throws UnknownHostException, IOException
server
- metric
- UnknownHostException
IOException
Copyright © 2004-2015. All Rights Reserved.