bharathv commented on a change in pull request #2769:
URL: https://github.com/apache/hbase/pull/2769#discussion_r600625117
##########
File path:
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
##########
@@ -1084,7 +1084,15 @@ public void run() {
}
long now = System.currentTimeMillis();
if ((now - lastMsg) >= msgInterval) {
+ // Register with the Master now that our setup is complete.
tryRegionServerReport(lastMsg, now);
Review comment:
@caroliney14 You missed my last comment on checking whether
tryRegionServerReport() was successful. It can also return _without_ sending a
report successfully. Ex: RS starts before master is up. Quoting my last comment
here again
> You need do this only if tryRegionServerReport() is successful. It can
also return without a successful report if the exception thrown is not
YouAreDeadException. You may need to make that method return a boolean that
tells the caller if the report was successfully sent.
So the code should be something like
```
boolean reportSuccess = tryRegionServerReport(...)
if (reportSuccess && !online.get()) {
....
}
```
+1 once that is done.
--
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]