advancedxy commented on code in PR #471:
URL: https://github.com/apache/incubator-uniffle/pull/471#discussion_r1071188864


##########
server/src/main/java/org/apache/uniffle/server/ShuffleTaskManager.java:
##########
@@ -200,7 +199,13 @@ public StatusCode registerShuffle(
   public StatusCode cacheShuffleData(
       String appId, int shuffleId, boolean isPreAllocated, 
ShufflePartitionedData spd) {
     refreshAppId(appId);
-    return shuffleBufferManager.cacheShuffleData(appId, shuffleId, 
isPreAllocated, spd);
+    return shuffleBufferManager.cacheShuffleData(
+        appId,
+        shuffleId,
+        isPreAllocated,
+        spd,
+        this::getPartitionDataSize

Review Comment:
   > If concurrently caching data for one partition, the function passing will 
be more accurate, because the partitionDataSize passed may be out of date.
   
   Yes. it would be more accurate. But I'm not sure it's worthing it.
   
   However I'm going to approve this for now. Let's see how it works in prod. 
Maybe we need to modify it later.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to