You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2021/08/27 04:53:47 UTC

[GitHub] [incubator-doris] weizuo93 commented on a change in pull request #6513: [Optimize][Clone] Take version count into consideration when choosing src replica for clone task

weizuo93 commented on a change in pull request #6513:
URL: https://github.com/apache/incubator-doris/pull/6513#discussion_r697151173



##########
File path: fe/fe-core/src/main/java/org/apache/doris/clone/TabletSchedCtx.java
##########
@@ -499,10 +501,17 @@ public void chooseSrcReplica(Map<Long, PathSlot> backendsWorkingSlots) throws Sc
             
             long srcPathHash = slot.takeSlot(srcReplica.getPathHash());
             if (srcPathHash != -1) {
-                setSrc(srcReplica);
-                return;
+                if (minVersionCount == -1 || srcReplica.getVersionCount() < minVersionCount) {
+                    minVersionCount = srcReplica.getVersionCount();

Review comment:
       > versionCount of a replica is set by report process.
   > It may be -1 if the report is not done yet.
   > So we need to check it.
   
   OK, thanks for your comment.




-- 
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: commits-unsubscribe@doris.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org