public class ComponentStatistics extends Object implements Statistics
clear() method is used.| Constructor and Description |
|---|
ComponentStatistics()
The constructor added to initialize the interval time in ms that stats are measured for from the property statIntervalTime.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCompleteExecutionTime(long time)
Add the complete execution time for a flow that also reports branch execution times.
|
void |
addExecutionBranchTime(boolean first,
long branch,
long total)
Add a new execution-time measurement for one branch of processing an event.
|
void |
addExecutionTime(long time)
Add a new execution-time measurement for processing an event.
|
void |
clear()
Resets the state of this component statistics collector.
|
long |
getAverageExecutionTime()
Returns the average execution time, rounded downwards.
|
long |
getExecutedEvents()
Then number of events executed since last cleared.
|
long |
getMaxExecutionTime()
The maximum total event execution time seen since last cleared.
|
long |
getMinExecutionTime()
The minimum total event execution time seen since last cleared.
|
long |
getTotalExecutionTime()
The total cumulative execution time since statistics were last cleared.
|
boolean |
isEnabled()
Returns true if this stats collector is enabled.
|
void |
logSummary() |
void |
logSummary(PrintWriter printer) |
void |
setEnabled(boolean enabled)
Tags this stats collector as enabled or disabled.
|
public ComponentStatistics()
public void clear()
public boolean isEnabled()
isEnabled in interface Statisticstrue if stats collection is enabled, otherwise false.public void logSummary()
public void logSummary(PrintWriter printer)
public void setEnabled(boolean enabled)
enabled - true if stats should be enabled, otherwise false.public long getMaxExecutionTime()
public long getMinExecutionTime()
public long getTotalExecutionTime()
public long getExecutedEvents()
addExecutionBranchTime(boolean, long, long).public void addExecutionBranchTime(boolean first,
long branch,
long total)
first - true if this is the first branch for this eventbranch - the time to execute this branchtotal - the total time (so far) for processing this eventpublic void addCompleteExecutionTime(long time)
addExecutionBranchTime(boolean, long, long).time - the total time required to process this eventpublic void addExecutionTime(long time)
addCompleteExecutionTime(long).time - The total event time to be logged/recorded.public long getAverageExecutionTime()
Copyright © 2003–2017 MuleSoft, Inc.. All rights reserved.