<div dir="ltr">Hi,<div><br></div><div>   I was wondering if there is a nice way to try and avoid buffer allocation when serializing objects. I have my own way of serializing objects, but the idea is very similar to ObjectEncoder, which allocates a new buffer for each written message. I understand that its very difficult to serialize directly to the socket in non blocking IO, but was wondering if there is a good way to not allocate a buffer each time but maybe reuse buffers.</div>

<div><br></div><div>   I could build my own cache of buffers, get one before writing and release it when the write is completed. Wondering if there is a better way to do it...</div><div><br></div><div>-shay.banon</div></div>