Package org.glassfish.pfl.tf.timer.impl
Class MultiThreadedStatsEventHandlerImpl
- java.lang.Object
-
- org.glassfish.pfl.tf.timer.spi.NamedBase
-
- org.glassfish.pfl.tf.timer.impl.StatsEventHandlerBase
-
- org.glassfish.pfl.tf.timer.impl.MultiThreadedStatsEventHandlerImpl
-
- All Implemented Interfaces:
Named
,StatsEventHandler
,TimerEventHandler
public class MultiThreadedStatsEventHandlerImpl extends StatsEventHandlerBase
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.Object
saListLock
private java.lang.ThreadLocal<java.util.ArrayList<java.util.Stack<TimerEvent>>>
tlsteList
-
Fields inherited from class org.glassfish.pfl.tf.timer.impl.StatsEventHandlerBase
saList, UNITS
-
-
Constructor Summary
Constructors Constructor Description MultiThreadedStatsEventHandlerImpl(TimerFactory factory, java.lang.String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
Discard all accumulated statistics.private java.util.Stack<TimerEvent>
getSteElement(int id)
void
notify(TimerEvent event)
protected void
recordDuration(int id, long duration)
-
Methods inherited from class org.glassfish.pfl.tf.timer.impl.StatsEventHandlerBase
notify, stats
-
Methods inherited from class org.glassfish.pfl.tf.timer.spi.NamedBase
equals, factory, hashCode, name, setFactory, toString
-
-
-
-
Field Detail
-
saListLock
private java.lang.Object saListLock
-
tlsteList
private java.lang.ThreadLocal<java.util.ArrayList<java.util.Stack<TimerEvent>>> tlsteList
-
-
Constructor Detail
-
MultiThreadedStatsEventHandlerImpl
MultiThreadedStatsEventHandlerImpl(TimerFactory factory, java.lang.String name)
-
-
Method Detail
-
getSteElement
private java.util.Stack<TimerEvent> getSteElement(int id)
-
clear
public void clear()
Description copied from interface:StatsEventHandler
Discard all accumulated statistics.- Specified by:
clear
in interfaceStatsEventHandler
- Overrides:
clear
in classStatsEventHandlerBase
-
recordDuration
protected void recordDuration(int id, long duration)
- Specified by:
recordDuration
in classStatsEventHandlerBase
-
notify
public void notify(TimerEvent event)
-
-