|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rhq.enterprise.communications.command.server.CommandProcessorMetrics
public class CommandProcessorMetrics
Contains the statistics collected by the CommandProcessor.
The processor object is the only object that can update metric data
held in this object and it will do so in a thread-safe manner.
Objects that read data from this object automatically do so in a thread-safe manner,
but the callers may get inconsistent data if the processor updates data
in between calling multiple getters - but this isn't dangerous
so we'll leave it as is (the individual getters makes it easy to expose
this information as individual metrics so we can graph them).
But the locking done here helps minimize those instances where metric data
looks inconsistent to callers.
| Nested Class Summary | |
|---|---|
class |
CommandProcessorMetrics.Calltime
Used to store the minimum, maximum and average times (in milliseconds) for invocations to a particular command. |
static class |
CommandProcessorMetrics.UnsuccessfulReason
|
| Constructor Summary | |
|---|---|
CommandProcessorMetrics()
|
|
| Method Summary | |
|---|---|
void |
clear()
Resets all the metric data to 0 and clears the calltime data. |
long |
getAverageExecutionTime()
Returns the average execution time (in milliseconds) it took to execute all successful commands. |
Map<String,CommandProcessorMetrics.Calltime> |
getCallTimeData()
Return the calltime data that includes the different command types/pojo invocations. |
long |
getNumberDroppedCommands()
Returns the total number of commands that were received but were not permitted to be executed and were dropped. |
long |
getNumberFailedCommands()
Returns the total number of commands that were received but failed to be processed succesfully. |
long |
getNumberNotProcessedCommands()
Returns the total number of commands that were received but were not processed. |
long |
getNumberSuccessfulCommands()
Returns the total number of commands that were received and processed succesfully. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CommandProcessorMetrics()
| Method Detail |
|---|
public void clear()
public Map<String,CommandProcessorMetrics.Calltime> getCallTimeData()
public long getNumberFailedCommands()
not successful. This does not count
dropped or
unprocessed commands.
public long getNumberDroppedCommands()
public long getNumberNotProcessedCommands()
public long getNumberSuccessfulCommands()
succesful.
public long getAverageExecutionTime()
successful commands.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||