diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ScannerCallableWithReplicas.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ScannerCallableWithReplicas.java index a197e9093ac..0fbb2e7cc64 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ScannerCallableWithReplicas.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ScannerCallableWithReplicas.java @@ -202,6 +202,9 @@ class ScannerCallableWithReplicas implements RetryingCallable { updateCurrentlyServingReplica(r.getSecond(), r.getFirst(), done, pool); } return r == null ? null : r.getFirst(); // great we got an answer + } else { + throw new IOException("Failed to get result within timeout, timeout=" + + timeout + "ms"); } } catch (ExecutionException e) { RpcRetryingCallerWithReadReplicas.throwEnrichedException(e, retries); @@ -216,7 +219,8 @@ class ScannerCallableWithReplicas implements RetryingCallable { // calls succeeded or failed. In all case, we stop all our tasks. cs.cancelAll(); } - return null; // unreachable + LOG.error("Imposible? Arrive at an unreachable line..."); // unreachable + throw new IOException("Imposible? Arrive at an unreachable line..."); } private void updateCurrentlyServingReplica(ScannerCallable scanner, Result[] result, diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMasterCommandLine.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMasterCommandLine.java index 0b94d24ef82..e53a7816b17 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMasterCommandLine.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMasterCommandLine.java @@ -103,8 +103,7 @@ public class HMasterCommandLine extends ServerCommandLine { // minRegionServers used to be minServers. Support it too. if (cmd.hasOption("minServers")) { String val = cmd.getOptionValue("minServers"); - getConf().setInt("hbase.regions.server.count.min", - Integer.parseInt(val)); + getConf().setInt("hbase.regions.server.count.min", Integer.parseInt(val)); LOG.debug("minServers set to " + val); }