devabhishekpal commented on code in PR #5154:
URL: https://github.com/apache/ozone/pull/5154#discussion_r1296069336


##########
hadoop-ozone/recon/src/main/resources/webapps/recon/ozone-recon-web/src/views/datanodes/datanodes.tsx:
##########
@@ -339,7 +341,14 @@ export class Datanodes extends 
React.Component<Record<string, object>, IDatanode
       loading: true,
       selectedColumns: this._getSelectedColumns(prevState.selectedColumns)
     }));
-    axios.get('/api/v1/datanodes').then(response => {
+
+    if (typeof cancelToken != typeof undefined){
+      //Some existing request might be there so we will cancel that before 
sending new request
+      cancelToken.cancel("Cancelling old datanode request");

Review Comment:
   Refactored abort requests in commit: 
[bded747](https://github.com/apache/ozone/pull/5154/commits/bded747b423c591f68b4ff8ffda1bf877c0395f7)



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