public static long getOptimalBufferSize ( long paramsLength , int numWorkers , int queueSize ) { // we add 64kb just for future proof volatility val bufferSize = ( ( paramsLength / 16 ) + 65536 ) * numWorkers * queueSize * 4 ; return bufferSize ; }
This method returns optimal bufferSize for a given model