Skip to content

Commit

Permalink
HBASE-23374 ExclusiveMemHFileBlock’s allocator should not be hardcode…
Browse files Browse the repository at this point in the history
…d as ByteBuffAllocator.HEAP

Signed-off-by: stack <stack@apache.org>
Signed-off-by: Jan Hentschel <janh@apache.org>
  • Loading branch information
chenxu14 authored and HorizonNet committed Dec 25, 2019
1 parent 1b049a2 commit 56f9db9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,9 @@ public class ExclusiveMemHFileBlock extends HFileBlock {
ExclusiveMemHFileBlock(BlockType blockType, int onDiskSizeWithoutHeader,
int uncompressedSizeWithoutHeader, long prevBlockOffset, ByteBuff buf, boolean fillHeader,
long offset, int nextBlockOnDiskSize, int onDiskDataSizeWithHeader,
HFileContext fileContext) {
HFileContext fileContext, ByteBuffAllocator alloc) {
super(blockType, onDiskSizeWithoutHeader, uncompressedSizeWithoutHeader, prevBlockOffset, buf,
fillHeader, offset, nextBlockOnDiskSize, onDiskDataSizeWithHeader, fileContext,
ByteBuffAllocator.HEAP);
fillHeader, offset, nextBlockOnDiskSize, onDiskDataSizeWithHeader, fileContext, alloc);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public HFileBlock build() {
} else {
return new ExclusiveMemHFileBlock(blockType, onDiskSizeWithoutHeader,
uncompressedSizeWithoutHeader, prevBlockOffset, buf, fillHeader, offset,
nextBlockOnDiskSize, onDiskDataSizeWithHeader, fileContext);
nextBlockOnDiskSize, onDiskDataSizeWithHeader, fileContext, allocator);
}
}
}

0 comments on commit 56f9db9

Please sign in to comment.