THRIFT-926. cpp: Better buffer management for TNonblockingServer
Add two improvements to memory management in TNonblocking server:
- Separate the receive code into two distinct states: one for receiving
the frame header and one for the frame content. This allows us to
size the initial read buffer based on the initial frame size, rather
than allocating an arbitrary amount of memory before reading the
header.
- Allow setting the initial write buffer size based on the application's
expected response size.
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@1005169 13f79535-47bb-0310-9956-ffa450edef68
2 files changed