public final class MessageProcessingStatsCollector extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
MessageProcessingStatsCollector.TypeStats
Contains message type specific stats
|
| Constructor and Description |
|---|
MessageProcessingStatsCollector(Boolean loggingEnabled,
String loggingLocation,
IdentityInformationProvider identityProvider,
Integer traceInterval,
IMessageProcessingStatsTracer tracer)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the stats collector
|
MessageProcessingStatsCollector |
enableLogging(boolean val)
Enable/disable logging
|
String |
getLogName()
Get the name of the underlying log
|
List<Class<?>> |
getTypes()
Get list of message types for which stats exist
|
MessageProcessingStatsCollector.TypeStats |
getTypeStats(Class<?> type)
Get the object containing stats for a specific message type
|
boolean |
isLoggingEnabled()
Get if logging is enabled
|
void |
log(MessageProcessingTime mpt)
Log a message processing time element
|
void |
open()
Open the stats collector
|
void |
reset()
Reset a stats collector
This method returns the stats collector to the state it was at
the time the collector was created
|
void |
scheduleLogCompactionOnNextWrite()
Schedule a compaction on the underlying on the next write
|
void |
setLogCompactionThreshold(int val)
Set the compaction threshold on the underlying log
|
void |
trace()
Output stats to tracer
|
@Inject public MessageProcessingStatsCollector(Boolean loggingEnabled, String loggingLocation, IdentityInformationProvider identityProvider, Integer traceInterval, IMessageProcessingStatsTracer tracer)
public final String getLogName()
public final MessageProcessingStatsCollector enableLogging(boolean val)
val - Specifies whether to switch logging on of off.
This method enables/disables logging (journalling) of message processing times. The method can be called at any time during the life of a message processing stats collector object.
public final boolean isLoggingEnabled()
public final void setLogCompactionThreshold(int val)
throws Exception
val - The compaction threshold to set in gigabytes. A value of 0 will switch off compactionExceptionpublic final void scheduleLogCompactionOnNextWrite()
throws Exception
Exceptionpublic final void log(MessageProcessingTime mpt)
public final MessageProcessingStatsCollector.TypeStats getTypeStats(Class<?> type)
public final void reset()
This method returns the stats collector to the state it was at the time the collector was created
public final void trace()
public final void close()
Copyright © 2016 Neeve Research, LLC. All Rights Reserved.