Convert the given message payload map to a bencoded byte stream.
byte[] raw_payload;
try {
raw_payload = BEncoder.encode( payload );
}
catch( Throwable t ) {
Debug.out( t );
raw_payload = new byte[0];
}
DirectByteBuffer buffer = DirectByteBufferPool.getBuffer( alloc_id, raw_payload.length );
buffer.put( DirectByteBuffer.SS_MSG, raw_payload );
buffer.flip( DirectByteBuffer.SS_MSG );
return buffer;