public abstract class DefaultMaxMessagesRecvByteBufAllocator extends Object implements MaxMessagesRecvByteBufAllocator
MaxMessagesRecvByteBufAllocator which respects ChannelConfig.isAutoRead()
and also prevents overflow.| Modifier and Type | Class and Description |
|---|---|
class |
DefaultMaxMessagesRecvByteBufAllocator.MaxMessageHandle
Focuses on enforcing the maximum messages per read condition for
DefaultMaxMessagesRecvByteBufAllocator.MaxMessageHandle.continueReading(). |
RecvByteBufAllocator.DelegatingHandle, RecvByteBufAllocator.ExtendedHandle, RecvByteBufAllocator.Handle| Constructor and Description |
|---|
DefaultMaxMessagesRecvByteBufAllocator() |
DefaultMaxMessagesRecvByteBufAllocator(int maxMessagesPerRead) |
| Modifier and Type | Method and Description |
|---|---|
int |
maxMessagesPerRead()
Returns the maximum number of messages to read per read loop.
|
MaxMessagesRecvByteBufAllocator |
maxMessagesPerRead(int maxMessagesPerRead)
Sets the maximum number of messages to read per read loop.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitnewHandlepublic DefaultMaxMessagesRecvByteBufAllocator()
public DefaultMaxMessagesRecvByteBufAllocator(int maxMessagesPerRead)
public int maxMessagesPerRead()
MaxMessagesRecvByteBufAllocatorchannelRead() event.
If this value is greater than 1, an event loop might attempt to read multiple times to procure multiple messages.maxMessagesPerRead in interface MaxMessagesRecvByteBufAllocatorpublic MaxMessagesRecvByteBufAllocator maxMessagesPerRead(int maxMessagesPerRead)
MaxMessagesRecvByteBufAllocatormaxMessagesPerRead in interface MaxMessagesRecvByteBufAllocatorCopyright © 2008–2017 The Netty Project. All rights reserved.