smengcl commented on code in PR #3837:
URL: https://github.com/apache/ozone/pull/3837#discussion_r998564308


##########
hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/views/missingContainers/missingContainers.tsx:
##########
@@ -192,16 +519,41 @@ export class MissingContainers extends 
React.Component<Record<string, object>, I
     this.setState({
       loading: true
     });
-    axios.get('/api/v1/containers/missing').then(response => {
-      const missingContainersResponse: IMissingContainersResponse = 
response.data;
-      const totalCount = missingContainersResponse.totalCount;
-      const missingContainers: IMissingContainerResponse[] = 
missingContainersResponse.containers;
+
+    axios.all([
+      axios.get('/api/v1/containers/missing'),
+      axios.get('/api/v1/containers/unhealthy/UNDER_REPLICATED'),
+      axios.get('/api/v1/containers/unhealthy/OVER_REPLICATED'),
+      axios.get('/api/v1/containers/unhealthy/MIS_REPLICATED'),
+      axios.get('/api/v1/containers/unhealthy/ALL_REPLICAS_UNHEALTHY'),
+    ]).then(axios.spread((missingContainersResponse, underReplicatedResponse, 
overReplicatedResponse, misReplicatedResponse, allReplicatedResponse) => {
+      
+      const missingContainersResponse1: IMissingContainersResponse = 
missingContainersResponse.data;

Review Comment:
   Pls avoid ambiguous variable names like this in non-test code. Better rename 
this to `missingContainersResponseData`?
   
   ```suggestion
         const missingContainersResponseData: IMissingContainersResponse = 
missingContainersResponse.data;
   ```



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