HBASE-13366 Throw DoNotRetryIOException instead of read only IOException (Shaohui Liu)

This commit is contained in:
Liu Shaohui 2015-04-02 11:52:54 +08:00
parent 485800830a
commit a609e5e107
1 changed files with 2 additions and 1 deletions

View File

@ -73,6 +73,7 @@ import org.apache.hadoop.hbase.Cell;
import org.apache.hadoop.hbase.CellScanner;
import org.apache.hadoop.hbase.CellUtil;
import org.apache.hadoop.hbase.CompoundConfiguration;
import org.apache.hadoop.hbase.DoNotRetryIOException;
import org.apache.hadoop.hbase.DroppedSnapshotException;
import org.apache.hadoop.hbase.HBaseConfiguration;
import org.apache.hadoop.hbase.HColumnDescriptor;
@ -3517,7 +3518,7 @@ public class HRegion implements HeapSize, PropagatingConfigurationObserver, Regi
*/
protected void checkReadOnly() throws IOException {
if (isReadOnly()) {
throw new IOException("region is read only");
throw new DoNotRetryIOException("region is read only");
}
}