public class AcsLoggerStatistics
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_STATISTICS_GRANULARITY |
static int |
DEFAULT_STATISTICS_PERIOD |
static boolean |
DEFAULT_STATISTICS_STATE |
static int |
INITIAL_NUMBER_ERRORS |
static int |
INITIAL_NUMBER_MESSAGES
These constant members represent the default values of the statistics parametres.
|
| Constructor and Description |
|---|
AcsLoggerStatistics()
Standard constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
calculateLoggingStatistics()
This method calculates the logging statistics
|
void |
configureStatistics(java.lang.String elementName,
boolean state,
int period,
int granularity)
This method allows the statistic module to be configured
|
int |
getAccumulatedNumberOfLogErrors() |
int |
getAccumulatedNumberOfMessages() |
float |
getActualStatisticsPeriod() |
java.lang.Boolean |
getDisableStatistics() |
float |
getErrorIncrement() |
float |
getErrorStatistics() |
int |
getLastPeriodNumberOfLogErrors() |
int |
getLastPeriodNumberOfMessages() |
long |
getLastStatisticsRepportTime() |
float |
getMessageIncrement() |
float |
getMessageStatistics() |
int |
getStatisticsCalculationPeriod() |
int |
getStatisticsGranularity() |
java.lang.String |
getStatisticsIdentification() |
void |
incrementNumberOfLogErrors()
This method increments the stored number of logging errors detected
|
void |
incrementNumberOfMessages()
This method increments the stored number of correctly transferred logs
|
void |
resetStatistics()
This method makes a backup and resets the current statisctics values
|
void |
retrieveStatisticsLogs(java.util.List<java.lang.String> statisticsLogList,
java.lang.String loggerId)
This method generates the logging statistics in message format
|
void |
setAccumulatedNumberOfLogErrors(int accumulatedNumberOfLogErrors) |
void |
setAccumulatedNumberOfMessages(int accumulatedNumberOfMessages) |
void |
setActualStatisticsPeriod(float actualStatisticsPeriod) |
void |
setDisableStatistics(java.lang.Boolean disableStatistics) |
void |
setErrorIncrement(float errorIncrement) |
void |
setErrorStatistics(float errorStatistics) |
void |
setLastPeriodNumberOfLogErrors(int lastPeriodNumberOfLogErrors) |
void |
setLastPeriodNumberOfMessages(int lastPeriodNumberOfMessages) |
void |
setLastStatisticsRepportTime(long lastStatisticsRepportTime) |
void |
setMessageIncrement(float messageIncrement) |
void |
setMessageStatistics(float messageStatistics) |
void |
setStatisticsCalculationPeriod(int statisticsCalculationPeriod) |
void |
setStatisticsGranularity(int statisticsGranularity) |
void |
setStatisticsIdentification(java.lang.String statisticsIdentification) |
public static final int INITIAL_NUMBER_MESSAGES
public static final int INITIAL_NUMBER_ERRORS
public static final int DEFAULT_STATISTICS_PERIOD
public static final int DEFAULT_STATISTICS_GRANULARITY
public static final boolean DEFAULT_STATISTICS_STATE
public void calculateLoggingStatistics()
public void retrieveStatisticsLogs(java.util.List<java.lang.String> statisticsLogList,
java.lang.String loggerId)
statisticsLogList - List of logs (strings)loggerId - String to indintify the logger
(normaly will consist on container name + logger name)public void incrementNumberOfMessages()
public void incrementNumberOfLogErrors()
public void resetStatistics()
public void configureStatistics(java.lang.String elementName,
boolean state,
int period,
int granularity)
elementName - String defining the name of the module the statistics belong tostate - Configuaration of disableStatistics attribute (to enable / diable statistics module)period - Configuration of statisticsCalculationPeriodgranularity - Configuration of statisticsGranularitypublic java.lang.Boolean getDisableStatistics()
public java.lang.String getStatisticsIdentification()
public int getAccumulatedNumberOfMessages()
public int getAccumulatedNumberOfLogErrors()
public long getLastStatisticsRepportTime()
public int getStatisticsCalculationPeriod()
public int getStatisticsGranularity()
public int getLastPeriodNumberOfMessages()
public int getLastPeriodNumberOfLogErrors()
public float getMessageStatistics()
public float getErrorStatistics()
public float getMessageIncrement()
public float getErrorIncrement()
public float getActualStatisticsPeriod()
public void setDisableStatistics(java.lang.Boolean disableStatistics)
public void setStatisticsIdentification(java.lang.String statisticsIdentification)
public void setAccumulatedNumberOfMessages(int accumulatedNumberOfMessages)
public void setAccumulatedNumberOfLogErrors(int accumulatedNumberOfLogErrors)
public void setLastStatisticsRepportTime(long lastStatisticsRepportTime)
public void setStatisticsCalculationPeriod(int statisticsCalculationPeriod)
public void setStatisticsGranularity(int statisticsGranularity)
public void setLastPeriodNumberOfMessages(int lastPeriodNumberOfMessages)
public void setLastPeriodNumberOfLogErrors(int lastPeriodNumberOfLogErrors)
public void setMessageStatistics(float messageStatistics)
public void setErrorStatistics(float errorStatistics)
public void setMessageIncrement(float messageIncrement)
public void setErrorIncrement(float errorIncrement)
public void setActualStatisticsPeriod(float actualStatisticsPeriod)