HBASE-12793 [hbck] closeRegionSilentlyAndWait() should log cause of IOException and retry until hbase.hbck.close.timeout expires (Esteban)
This commit is contained in:
parent
f9873622b8
commit
071c3026f0
|
@ -25,6 +25,7 @@ import org.apache.hadoop.fs.Path;
|
|||
import org.apache.hadoop.hbase.HRegionInfo;
|
||||
import org.apache.hadoop.hbase.HTableDescriptor;
|
||||
import org.apache.hadoop.hbase.MetaTableAccessor;
|
||||
import org.apache.hadoop.hbase.NotServingRegionException;
|
||||
import org.apache.hadoop.hbase.ServerName;
|
||||
import org.apache.hadoop.hbase.TableName;
|
||||
import org.apache.hadoop.hbase.ZooKeeperConnectionException;
|
||||
|
@ -166,7 +167,9 @@ public class HBaseFsckRepair {
|
|||
ProtobufUtil.getRegionInfo(rs, region.getRegionName());
|
||||
if (rsRegion == null) return;
|
||||
} catch (IOException ioe) {
|
||||
return;
|
||||
if (ioe instanceof NotServingRegionException) // no need to retry again
|
||||
return;
|
||||
LOG.warn("Exception when retrieving regioninfo from: " + region.getRegionNameAsString(), ioe);
|
||||
}
|
||||
Thread.sleep(1000);
|
||||
}
|
||||
|
|
|
@ -151,6 +151,7 @@ public class TestHBaseFsck {
|
|||
conf.setInt("hbase.htable.threads.max", POOL_SIZE);
|
||||
conf.setInt("hbase.hconnection.threads.max", 2 * POOL_SIZE);
|
||||
conf.setInt("hbase.hconnection.threads.core", POOL_SIZE);
|
||||
conf.setInt("hbase.hbck.close.timeout", 2 * REGION_ONLINE_TIMEOUT);
|
||||
TEST_UTIL.startMiniCluster(3);
|
||||
|
||||
tableExecutorService = new ThreadPoolExecutor(1, POOL_SIZE, 60, TimeUnit.SECONDS,
|
||||
|
|
Loading…
Reference in New Issue