jojochuang commented on code in PR #8655:
URL: https://github.com/apache/ozone/pull/8655#discussion_r2246502614


##########
hadoop-ozone/ozone-manager/src/main/resources/webapps/ozoneManager/ozoneManager.js:
##########
@@ -129,19 +151,20 @@
                 .then(function (result) {
                     ctrl.elapsedTime = result.data.beans[0];
                     if(ctrl.elapsedTime.Value != -1){
-                        ctrl.elapsedTime.Value = 
convertMsToTime(ctrl.elapsedTime.Value);
+                        ctrl.elapsedTime.Value = 
ctrl.convertMsToTime(ctrl.elapsedTime.Value);
+                    }
+                });
+
+            // Add JMX query to fetch DeletingServiceMetrics data
+            
$http.get("jmx?qry=Hadoop:service=OzoneManager,name=DeletingServiceMetrics")
+                .then(function (result) {
+                    if (result.data.beans && result.data.beans.length > 0) {
+                        // Merge the DeletingServiceMetrics data into the 
existing overview.jmx object
+                        ctrl.overview.jmx = {...ctrl.overview.jmx, 
...result.data.beans[0]};
                     }
                 });
         }
     });
-        function convertMsToTime(ms) {
-          let seconds = (ms / 1000).toFixed(1);
-          let minutes = (ms / (1000 * 60)).toFixed(1);
-          let hours = (ms / (1000 * 60 * 60)).toFixed(1);
-          let days = (ms / (1000 * 60 * 60 * 24)).toFixed(1);
-          if (seconds < 60) return seconds + " Seconds";
-          else if (minutes < 60) return minutes + " Minutes";
-          else if (hours < 24) return hours + " Hours";
-          else return days + " Days"
-        }
 })();
+
+

Review Comment:
   ```suggestion
   ```



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