HDFS-8719. Erasure Coding: client generates too many small packets when writing parity data. Contributed by Li Bo.
This commit is contained in:
parent
42a1d0dbde
commit
48f3830f21
@ -332,3 +332,6 @@
|
||||
|
||||
HDFS-8461. Erasure coding: fix priority level of UnderReplicatedBlocks for
|
||||
striped block. (Walter Su via jing9)
|
||||
|
||||
HDFS-8719. Erasure Coding: client generates too many small packets when
|
||||
writing parity data. (Li Bo via waltersu4549)
|
||||
|
@ -459,7 +459,7 @@ void setCurrentPacket2Empty() throws InterruptedIOException {
|
||||
* write filled up its partial chunk. Tell the summer to generate full
|
||||
* crc chunks from now on.
|
||||
*/
|
||||
private void adjustChunkBoundary() {
|
||||
protected void adjustChunkBoundary() {
|
||||
if (streamer.getAppendChunk() &&
|
||||
streamer.getBytesCurBlock() % bytesPerChecksum == 0) {
|
||||
streamer.setAppendChunk(false);
|
||||
|
@ -318,6 +318,7 @@ private synchronized StripedDataStreamer getCurrentStreamer() {
|
||||
|
||||
private synchronized StripedDataStreamer setCurrentStreamer(int i) {
|
||||
streamer = streamers.get(i);
|
||||
adjustChunkBoundary();
|
||||
return getCurrentStreamer();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user