Documentation
¶
Overview ¶
Package thrift code has been copied from https://github.com/m3dbx/thrift branch 0.9.3-patch This provides support for multiple byte slice pools of different capacities. see:https://github.com/m3dbx/thrift/blob/0.9.3-patch/lib/go/thrift/binary_protocol.go#L40
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BytesPoolGet ¶
BytesPoolGet returns a pooled byte slice of capacity BytesPoolAlloc.
func BytesPoolPut ¶
BytesPoolPut is a public func to call to return pooled bytes to, each the capacity of BytesPoolAlloc. TBinaryProtocol.ReadBinary uses this pool to allocate from if the size of the bytes required to return is is equal or less than BytesPoolAlloc.
func SetMaxBytesPoolAlloc ¶
func SetMaxBytesPoolAlloc(capacities ...int)
SetMaxBytesPoolAlloc sets the capacities of byte slices that are pooled for binary thrift fields and must be called before any thrift binary protocols are used since it is a global and is not thread safe to edit.
Types ¶
This section is empty.