caiconghui commented on a change in pull request #5133:
URL: https://github.com/apache/incubator-doris/pull/5133#discussion_r548804127



##########
File path: fe/fe-core/src/main/java/org/apache/doris/qe/Coordinator.java
##########
@@ -1560,14 +1560,20 @@ private void 
getExecHostPortForFragmentIDAndBucketSeq(TScanRangeLocations seqLoc
                     break;
                 }
             }
-
-            buckendIdToBucketCountMap.put(buckendId, 
buckendIdToBucketCountMap.get(buckendId) + 1);
             Reference<Long> backendIdRef = new Reference<Long>();
             TNetworkAddress execHostPort = SimpleScheduler.getHost(buckendId, 
seqLocation.locations, idToBackend, backendIdRef);
             if (execHostPort == null) {
                 throw new UserException("there is no scanNode Backend");
             }
-
+            if (backendIdRef.getRef() != buckendId) {
+                if 
(!buckendIdToBucketCountMap.containsKey(backendIdRef.getRef())) {
+                    buckendIdToBucketCountMap.put(backendIdRef.getRef(), 1);
+                } else {
+                    buckendIdToBucketCountMap.put(backendIdRef.getRef(), 
buckendIdToBucketCountMap.get(backendIdRef.getRef())+1);

Review comment:
       ```suggestion
                       buckendIdToBucketCountMap.put(backendIdRef.getRef(), 
buckendIdToBucketCountMap.get(backendIdRef.getRef()) + 1);
   ```




----------------------------------------------------------------
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:
us...@infra.apache.org



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

Reply via email to