|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.opennms.netmgt.dao.support.DefaultRrdDao
public class DefaultRrdDao
| Constructor Summary | |
|---|---|
DefaultRrdDao()
|
|
| Method Summary | |
|---|---|
void |
afterPropertiesSet()
|
InputStream |
createGraph(String command,
File workDir)
Create an RRD graph. |
int |
getGraphLeftOffset()
Gets the offset of the left side of the graph box from the left side of the image. |
int |
getGraphRightOffset()
Gets the offset of the right side of the graph box from the right side of the image. |
int |
getGraphTopOffsetWithText()
Gets the offset of the top of the graph box from the top of the image. |
Double |
getLastFetchValue(OnmsAttribute attribute,
int interval)
This method issues an round robin fetch command to retrieve the last value of the data source stored in the specified RRD file. |
Double |
getLastFetchValue(OnmsAttribute attribute,
int interval,
int range)
This method issues an round robin fetch command to retrieve the last value of the data source stored in the specified RRD file. |
double |
getPrintValue(OnmsAttribute attribute,
String cf,
long start,
long end)
Get the value for an attribute over a period of time. |
double[] |
getPrintValues(OnmsAttribute attribute,
String rraConsolidationFunction,
long startTimeInMillis,
long endTimeInMillis,
String... printFunctions)
Get the value for an attribute over a period of time. |
File |
getRrdBaseDirectory()
|
String |
getRrdBinaryPath()
|
RrdStrategy |
getRrdStrategy()
|
void |
setRrdBaseDirectory(File rrdBaseDirectory)
|
void |
setRrdBinaryPath(String rrdBinaryPath)
|
void |
setRrdStrategy(RrdStrategy rrdStrategy)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultRrdDao()
| Method Detail |
|---|
public double getPrintValue(OnmsAttribute attribute,
String cf,
long start,
long end)
RrdDao
getPrintValue in interface RrdDaoattribute - the attributecf - consolidation function (usually "AVERAGE")start - start time in millisecondsend - end time in milliseconds
public double[] getPrintValues(OnmsAttribute attribute,
String rraConsolidationFunction,
long startTimeInMillis,
long endTimeInMillis,
String... printFunctions)
RrdDao
getPrintValues in interface RrdDaoattribute - the attributerraConsolidationFunction - consolidation function (usually "AVERAGE")startTimeInMillis - start time in millisecondsendTimeInMillis - end time in milliseconds
public void afterPropertiesSet()
throws Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanExceptionpublic RrdStrategy getRrdStrategy()
public void setRrdStrategy(RrdStrategy rrdStrategy)
public File getRrdBaseDirectory()
public void setRrdBaseDirectory(File rrdBaseDirectory)
public String getRrdBinaryPath()
public void setRrdBinaryPath(String rrdBinaryPath)
public InputStream createGraph(String command,
File workDir)
throws org.springframework.dao.DataRetrievalFailureException
createGraph in interface RrdDaocommand - RRD graph commandworkDir - RRD files are relative to this directory
org.springframework.dao.DataRetrievalFailureException - if the graph could not be createdRrdDao.createGraph(java.lang.String, java.io.File)public int getGraphTopOffsetWithText()
RrdDao
getGraphTopOffsetWithText in interface RrdDaoRrdDao.getGraphTopOffsetWithText()public int getGraphLeftOffset()
RrdDao
getGraphLeftOffset in interface RrdDaoRrdDao.getGraphLeftOffset()public int getGraphRightOffset()
RrdDao
getGraphRightOffset in interface RrdDaoRrdDao.getGraphRightOffset()
public Double getLastFetchValue(OnmsAttribute attribute,
int interval)
throws org.springframework.dao.DataAccessResourceFailureException
RrdDao
getLastFetchValue in interface RrdDaoattribute - The attribute for which fetch the last value. Must be a
RrdGraphAttribute.interval - Fetch interval. This should equal RRD step size.
org.springframework.dao.DataAccessResourceFailureException
public Double getLastFetchValue(OnmsAttribute attribute,
int interval,
int range)
throws org.springframework.dao.DataAccessResourceFailureException
RrdDao
getLastFetchValue in interface RrdDaoattribute - The attribute for which fetch the last value. Must be a
RrdGraphAttribute.interval - Fetch interval in milliseconds. This should equal the RRD
step size.range - Interval in milliseconds for how long we should look back
in time for a non-NaN value. This should a multiple of
the RRD step size.
org.springframework.dao.DataAccessResourceFailureException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||