kishorvpatil commented on a change in pull request #3140: STORM-3188: Remove
try-catch block from getAndResetWorkerHeartbeats
URL: https://github.com/apache/storm/pull/3140#discussion_r333811329
##########
File path:
storm-server/src/main/java/org/apache/storm/daemon/supervisor/timer/ReportWorkerHeartbeats.java
##########
@@ -50,13 +50,8 @@ public void run() {
private SupervisorWorkerHeartbeats getAndResetWorkerHeartbeats() {
Map<String, LSWorkerHeartbeat> localHeartbeats;
- try {
- localHeartbeats = SupervisorUtils.readWorkerHeartbeats(this.conf);
- return getSupervisorWorkerHeartbeatsFromLocal(localHeartbeats);
- } catch (Exception e) {
- LOG.error("Read local worker heartbeats error, skipping heartbeats
for this round, msg:{}", e.getMessage());
- return null;
- }
+ localHeartbeats = SupervisorUtils.readWorkerHeartbeats(this.conf);
+ return getSupervisorWorkerHeartbeatsFromLocal(localHeartbeats);
Review comment:
The method is called in from run method
https://github.com/apache/storm/blob/master/storm-server/src/main/java/org/apache/storm/daemon/supervisor/timer/ReportWorkerHeartbeats.java#L45-L49
This try catch loop ensures that thread does not die.
Not sure what this PR is trying to accomplish. Please elaborate.
----------------------------------------------------------------
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]
With regards,
Apache Git Services