HDFS-12635. Unnecessary exception declaration of the CellBuffers constructor. Contributed by Huafeng Wang

This commit is contained in:
Kai Zheng 2017-10-11 15:47:00 +08:00
parent 372997f395
commit 8947c0b881
1 changed files with 2 additions and 7 deletions

View File

@ -198,7 +198,7 @@ public class DFSStripedOutputStream extends DFSOutputStream
private final ByteBuffer[] buffers;
private final byte[][] checksumArrays;
CellBuffers(int numParityBlocks) throws InterruptedException{
CellBuffers(int numParityBlocks) {
if (cellSize % bytesPerChecksum != 0) {
throw new HadoopIllegalArgumentException("Invalid values: "
+ HdfsClientConfigKeys.DFS_BYTES_PER_CHECKSUM_KEY + " (="
@ -304,12 +304,7 @@ public class DFSStripedOutputStream extends DFSOutputStream
ecPolicy.getCodecName(), coderOptions);
coordinator = new Coordinator(numAllBlocks);
try {
cellBuffers = new CellBuffers(numParityBlocks);
} catch (InterruptedException ie) {
throw DFSUtilClient.toInterruptedIOException(
"Failed to create cell buffers", ie);
}
cellBuffers = new CellBuffers(numParityBlocks);
streamers = new ArrayList<>(numAllBlocks);
for (short i = 0; i < numAllBlocks; i++) {