Open
Description
Consider pooling AsioBuffer
s instead of allocating them from the heap each time one is needed. However, if an unusually large message is sent or received rarely, that pooled buffer will needlessly waste memory. The pool should somehow be smart enough to discard such unusually large buffers.
I have considered chaining fixed-size chunks to form arbitrarily-sized buffers, but AFAICT, the msgpack-c unpacker needs the message to be completely contiguous in memory.