Package org.apache.zookeeper.server.util
Class RequestPathMetricsCollector
- java.lang.Object
-
- org.apache.zookeeper.server.util.RequestPathMetricsCollector
-
public class RequestPathMetricsCollector extends java.lang.ObjectThis class holds the requests path ( up till a certain depth) stats per request type
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringPATH_STATS_COLLECTOR_DELAYstatic java.lang.StringPATH_STATS_COLLECTOR_INITIAL_DELAYstatic java.lang.StringPATH_STATS_ENABLEDstatic java.lang.StringPATH_STATS_MAX_DEPTHstatic java.lang.StringPATH_STATS_SAMPLE_RATEstatic java.lang.StringPATH_STATS_SLOT_CAPACITYstatic java.lang.StringPATH_STATS_SLOT_DURATIONstatic java.lang.StringPATH_STATS_TOP_PATH_MAX
-
Constructor Summary
Constructors Constructor Description RequestPathMetricsCollector()RequestPathMetricsCollector(boolean accurateMode)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddumpTopPaths(java.io.PrintWriter pwriter, int queryMaxDepth)voiddumpTopReadPaths(java.io.PrintWriter pwriter, int queryMaxDepth)voiddumpTopRequestPath(java.io.PrintWriter pwriter, java.lang.String requestTypeName, int queryMaxDepth)voiddumpTopWritePaths(java.io.PrintWriter pwriter, int queryMaxDepth)voidregisterRequest(int type, java.lang.String path)The public interface of the buffer.voidshutdown()voidstart()
-
-
-
Field Detail
-
PATH_STATS_SLOT_CAPACITY
public static final java.lang.String PATH_STATS_SLOT_CAPACITY
- See Also:
- Constant Field Values
-
PATH_STATS_SLOT_DURATION
public static final java.lang.String PATH_STATS_SLOT_DURATION
- See Also:
- Constant Field Values
-
PATH_STATS_MAX_DEPTH
public static final java.lang.String PATH_STATS_MAX_DEPTH
- See Also:
- Constant Field Values
-
PATH_STATS_SAMPLE_RATE
public static final java.lang.String PATH_STATS_SAMPLE_RATE
- See Also:
- Constant Field Values
-
PATH_STATS_COLLECTOR_INITIAL_DELAY
public static final java.lang.String PATH_STATS_COLLECTOR_INITIAL_DELAY
- See Also:
- Constant Field Values
-
PATH_STATS_COLLECTOR_DELAY
public static final java.lang.String PATH_STATS_COLLECTOR_DELAY
- See Also:
- Constant Field Values
-
PATH_STATS_TOP_PATH_MAX
public static final java.lang.String PATH_STATS_TOP_PATH_MAX
- See Also:
- Constant Field Values
-
PATH_STATS_ENABLED
public static final java.lang.String PATH_STATS_ENABLED
- See Also:
- Constant Field Values
-
-
Method Detail
-
shutdown
public void shutdown()
-
start
public void start()
-
registerRequest
public void registerRequest(int type, java.lang.String path)The public interface of the buffer. FinalRequestHandler will call into this for each request that has a path and this needs to be fast. we sample the path so that we don't have to store too many paths in memory
-
dumpTopRequestPath
public void dumpTopRequestPath(java.io.PrintWriter pwriter, java.lang.String requestTypeName, int queryMaxDepth)
-
dumpTopReadPaths
public void dumpTopReadPaths(java.io.PrintWriter pwriter, int queryMaxDepth)
-
dumpTopWritePaths
public void dumpTopWritePaths(java.io.PrintWriter pwriter, int queryMaxDepth)
-
dumpTopPaths
public void dumpTopPaths(java.io.PrintWriter pwriter, int queryMaxDepth)
-
-