GeezerVison is showing netty.io — HAProxyMessageDecoder (Netty API Reference (4.1.141.Final))
Class HAProxyMessageDecoder
-
-
-
Constructor Summary
Constructors
Constructor
Description
Creates a new decoder with no additional data (TLV) restrictions, and should throw an exception as soon as
we exceed maxLength.
Creates a new decoder with no additional data (TLV) restrictions, whether or not to throw an exception as soon
as we exceed maxLength.
Creates a new decoder with restricted additional data (TLV) size, and should throw an exception as soon as
we exceed maxLength.
Creates a new decoder with restricted additional data (TLV) size, whether or not to throw an exception as soon
as we exceed maxLength.
-
Method Summary
Modifier and Type
Method
Description
void
protected final void
Decode the from one ByteBuf to an other.
boolean
actualReadableBytes, callDecode, channelInactive, channelReadComplete, decodeLast, discardSomeReadBytes, handlerRemoved, handlerRemoved0, internalBuffer, setCumulator, setDiscardAfterReads, setSingleDecode, userEventTriggered
Modifier and Type
Method
Description
protected int
Returns the actual number of readable bytes in the internal cumulative
buffer of this decoder.
protected void
Called once data should be decoded from the given ByteBuf.
void
void
protected void
protected final void
final void
Do nothing by default, sub-classes may override this method.
protected void
Gets called after the ByteToMessageDecoder was removed from the actual context and it doesn't handle
events anymore.
Returns the internal cumulative buffer of this decoder.
void
void
void
void
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
HAProxyMessageDecoder
public HAProxyMessageDecoder()
Creates a new decoder with no additional data (TLV) restrictions, and should throw an exception as soon as
we exceed maxLength.
-
HAProxyMessageDecoder
public HAProxyMessageDecoder(boolean failFast)
Creates a new decoder with no additional data (TLV) restrictions, whether or not to throw an exception as soon
as we exceed maxLength.
- Parameters:
failFast - Whether or not to throw an exception as soon as we exceed maxLength
-
HAProxyMessageDecoder
public HAProxyMessageDecoder(int maxTlvSize)
Creates a new decoder with restricted additional data (TLV) size, and should throw an exception as soon as
we exceed maxLength.
Note: limiting TLV size only affects processing of v2, binary headers. Also, as allowed by the 1.5 spec
TLV data is currently ignored. For maximum performance it would be best to configure your upstream proxy host to
NOT send TLV data and instantiate with a max TLV size of 0.
- Parameters:
maxTlvSize - maximum number of bytes allowed for additional data (Type-Length-Value vectors) in a v2 header
-
HAProxyMessageDecoder
public HAProxyMessageDecoder(int maxTlvSize,
boolean failFast)
Creates a new decoder with restricted additional data (TLV) size, whether or not to throw an exception as soon
as we exceed maxLength.
- Parameters:
maxTlvSize - maximum number of bytes allowed for additional data (Type-Length-Value vectors) in a v2 header
failFast - Whether or not to throw an exception as soon as we exceed maxLength
-
|