walterddr commented on code in PR #11785:
URL: https://github.com/apache/pinot/pull/11785#discussion_r1359064010


##########
pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotSegmentRestletResource.java:
##########
@@ -700,19 +699,24 @@ public ServerReloadControllerJobStatusResponse 
getReloadJobStatus(
     
serverReloadControllerJobStatusResponse.setTotalServersQueried(serverUrls.size());
     
serverReloadControllerJobStatusResponse.setTotalServerCallsFailed(serviceResponse._failedResponseCount);
 
+    // Merge all server responses.
+    List<String> pendingSegments = new ArrayList<>();
+    int successCount = 0;
     for (Map.Entry<String, String> streamResponse : 
serviceResponse._httpResponses.entrySet()) {
       String responseString = streamResponse.getValue();
       try {
         ServerReloadControllerJobStatusResponse response =
             JsonUtils.stringToObject(responseString, 
ServerReloadControllerJobStatusResponse.class);
-        serverReloadControllerJobStatusResponse.setSuccessCount(
-            serverReloadControllerJobStatusResponse.getSuccessCount() + 
response.getSuccessCount());
+        successCount += response.getSuccessCount();
+        pendingSegments.addAll(response.getPendingSegments());

Review Comment:
   hmm. first of all i dont know why this json is decoded into the controller 
side class, (where it should really be the server side class) see comment: 
https://github.com/apache/pinot/pull/8828/files#r1359063941
   
   CC @saurabhd336 please kindly share your thoughts?



-- 
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-unsubscr...@pinot.apache.org

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


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

Reply via email to