You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/05/08 01:49:34 UTC

[GitHub] [spark] Ngone51 commented on a change in pull request #32389: [SPARK-35263] [TEST] Refactor ShuffleBlockFetcherIteratorSuite to reduce duplicated code

Ngone51 commented on a change in pull request #32389:
URL: https://github.com/apache/spark/pull/32389#discussion_r628664369



##########
File path: core/src/test/scala/org/apache/spark/storage/ShuffleBlockFetcherIteratorSuite.scala
##########
@@ -123,6 +131,54 @@ class ShuffleBlockFetcherIteratorSuite extends SparkFunSuite with PrivateMethodT
     verify(wrappedInputStream.invokePrivate(delegateAccess()), times(1)).close()
   }
 
+  /**
+   * Get a blockByAddress iterator for a single BlockManagerId assuming all blocks have the same
+   * size and `blockMapId`.
+   */
+  private def getBlocksByAddressForSingleBM(
+      blockManagerId: BlockManagerId,
+      blocks: Traversable[BlockId],
+      blockSize: Long,
+      blockMapId: Int): Iterator[(BlockManagerId, Seq[(BlockId, Long, Int)])] = {

Review comment:
       This should be `mapIndex` instead of `mapId`. Could you rename it to `blockMapIndex`?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org