Issue: There is a lot of byte[] allocated when handling TCP messages:

It's better to have a ByteArray pool allocator so that byte[] can be reused and avoid creating massive garbage for the GC and the throughput can be even better.
For example:
ByteArrayPoolAllocator pool = ByteArrayPoolAllocator.DEFAULT
byte[10] obj = byteArrayPool.getByteArray(10);
Issue: There is a lot of
byte[]allocated when handling TCP messages:It's better to have a ByteArray pool allocator so that
byte[]can be reused and avoid creating massive garbage for the GC and the throughput can be even better.For example: