Package com.google.code.yanf4j.config
Class Configuration
- java.lang.Object
-
- com.google.code.yanf4j.config.Configuration
-
public class Configuration extends java.lang.Object
Networking configuration
-
-
Field Summary
Fields Modifier and Type Field Description private long
checkSessionTimeoutInterval
check session idle intervalstatic int
DEFAULT_INCREASE_BUFF_SIZE
Increasing buffer size per timeprivate int
dispatchMessageThreadCount
Thread coount for processing message dispatchingprivate boolean
handleReadWriteConcurrently
Whether to handle read write concurrently,default is truestatic int
MAX_READ_BUFFER_SIZE
Max read buffer size for connectionprivate int
readThreadCount
THread count for processing READABLE eventprivate int
selectorPoolSize
private long
sessionIdleTimeout
private int
sessionReadBufferSize
Read buffer size per connectionprivate int
soTimeout
Socket SO_TIMEOUT optionprotected long
statisticsInterval
private boolean
statisticsServer
Whether to enable statisticsprivate int
writeThreadCount
Thread count for processing WRITABLE eventstatic java.lang.String
XMEMCACHED_SELECTOR_POOL_SIZE
-
Constructor Summary
Constructors Constructor Description Configuration()
-
Method Summary
-
-
-
Field Detail
-
XMEMCACHED_SELECTOR_POOL_SIZE
public static final java.lang.String XMEMCACHED_SELECTOR_POOL_SIZE
- See Also:
- Constant Field Values
-
sessionReadBufferSize
private int sessionReadBufferSize
Read buffer size per connection
-
soTimeout
private int soTimeout
Socket SO_TIMEOUT option
-
writeThreadCount
private int writeThreadCount
Thread count for processing WRITABLE event
-
statisticsServer
private boolean statisticsServer
Whether to enable statistics
-
handleReadWriteConcurrently
private boolean handleReadWriteConcurrently
Whether to handle read write concurrently,default is true
-
dispatchMessageThreadCount
private int dispatchMessageThreadCount
Thread coount for processing message dispatching
-
readThreadCount
private int readThreadCount
THread count for processing READABLE event
-
selectorPoolSize
private int selectorPoolSize
-
DEFAULT_INCREASE_BUFF_SIZE
public static final int DEFAULT_INCREASE_BUFF_SIZE
Increasing buffer size per time- See Also:
- Constant Field Values
-
MAX_READ_BUFFER_SIZE
public static final int MAX_READ_BUFFER_SIZE
Max read buffer size for connection- See Also:
- Constant Field Values
-
checkSessionTimeoutInterval
private long checkSessionTimeoutInterval
check session idle interval
-
sessionIdleTimeout
private long sessionIdleTimeout
-
statisticsInterval
protected long statisticsInterval
-
-
Method Detail
-
getWriteThreadCount
public final int getWriteThreadCount()
-
getDispatchMessageThreadCount
public final int getDispatchMessageThreadCount()
-
setDispatchMessageThreadCount
public final void setDispatchMessageThreadCount(int dispatchMessageThreadCount)
-
setWriteThreadCount
public final void setWriteThreadCount(int writeThreadCount)
-
getSessionIdleTimeout
public final long getSessionIdleTimeout()
- Returns:
- See Also:
setSessionIdleTimeout(long)
-
setSessionIdleTimeout
public final void setSessionIdleTimeout(long sessionIdleTimeout)
-
getSessionReadBufferSize
public final int getSessionReadBufferSize()
- Returns:
- See Also:
setSessionReadBufferSize(int)
-
isHandleReadWriteConcurrently
public final boolean isHandleReadWriteConcurrently()
-
getSoTimeout
public final int getSoTimeout()
-
getStatisticsInterval
public final long getStatisticsInterval()
-
setStatisticsInterval
public final void setStatisticsInterval(long statisticsInterval)
-
setSoTimeout
public final void setSoTimeout(int soTimeout)
-
setHandleReadWriteConcurrently
public final void setHandleReadWriteConcurrently(boolean handleReadWriteConcurrently)
-
setSessionReadBufferSize
public final void setSessionReadBufferSize(int tcpHandlerReadBufferSize)
-
isStatisticsServer
public final boolean isStatisticsServer()
-
setStatisticsServer
public final void setStatisticsServer(boolean statisticsServer)
-
getReadThreadCount
public final int getReadThreadCount()
- Returns:
- See Also:
setReadThreadCount(int)
-
setReadThreadCount
public final void setReadThreadCount(int readThreadCount)
-
setCheckSessionTimeoutInterval
public void setCheckSessionTimeoutInterval(long checkSessionTimeoutInterval)
-
getCheckSessionTimeoutInterval
public long getCheckSessionTimeoutInterval()
-
setSelectorPoolSize
public void setSelectorPoolSize(int selectorPoolSize)
-
getSelectorPoolSize
public int getSelectorPoolSize()
-
-