moleske commented on a change in pull request #6125:
URL: https://github.com/apache/geode/pull/6125#discussion_r593364495
##########
File path:
geode-core/src/main/java/org/apache/geode/internal/statistics/platform/LinuxProcFsStatistics.java
##########
@@ -156,14 +152,24 @@ public static void refreshProcess(int pid,
LocalStatisticsImpl stats) {
}
public static void refreshSystem(LocalStatisticsImpl stats) {
+ try {
+ refreshSystem(stats, new FileInputStream("/proc/stat"),
+ new FileInputStream("/proc/net/netstat"));
Review comment:
I ended up changing refreshSystem to take in file paths to have only one
try/catch. There was a scenario I thought of where if I kept the try and it
failed to FileInputStream, it wouldn't update the other stats. The original
code would attempt to update the other stats if the FileInputStream failed
----------------------------------------------------------------
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:
[email protected]