org.apache.zookeeper.server
Class SyncRequestProcessor
java.lang.Object
java.lang.Thread
org.apache.zookeeper.server.SyncRequestProcessor
- All Implemented Interfaces:
- Runnable, RequestProcessor
public class SyncRequestProcessor
- extends Thread
- implements RequestProcessor
This RequestProcessor logs requests to disk. It batches the requests to do
the io efficiently. The request is not passed to the next RequestProcessor
until its log has been synced to disk.
Methods inherited from class java.lang.Thread |
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
SyncRequestProcessor
public SyncRequestProcessor(ZooKeeperServer zks,
RequestProcessor nextProcessor)
setSnapCount
public static void setSnapCount(int count)
- used by tests to check for changing
snapcounts
- Parameters:
count
-
getSnapCount
public static int getSnapCount()
- used by tests to get the snapcount
- Returns:
- the snapcount
run
public void run()
- Specified by:
run
in interface Runnable
- Overrides:
run
in class Thread
shutdown
public void shutdown()
- Specified by:
shutdown
in interface RequestProcessor
processRequest
public void processRequest(Request request)
- Specified by:
processRequest
in interface RequestProcessor
Copyright © 2012 The Apache Software Foundation