You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by GitBox <gi...@apache.org> on 2019/05/30 12:42:20 UTC

[GitHub] [hbase] openinx commented on a change in pull request #268: HBASE-22491 Separate the heap HFileBlock and offheap HFileBlock because the heap block won't need refCnt and save into prevBlocks list before shipping

openinx commented on a change in pull request #268: HBASE-22491 Separate the heap HFileBlock and offheap HFileBlock because the heap block won't need refCnt and save into prevBlocks list before shipping
URL: https://github.com/apache/hbase/pull/268#discussion_r288973970
 
 

 ##########
 File path: hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/HFileReaderImpl.java
 ##########
 @@ -523,15 +523,15 @@ void updateCurrBlockRef(HFileBlock block) {
       if (block != null && curBlock != null && block.getOffset() == curBlock.getOffset()) {
         return;
       }
-      if (this.curBlock != null) {
+      if (this.curBlock != null && !this.curBlock.isOnHeap()) {
 
 Review comment:
   Discussed with @anoopsjohn before,  Maitaining a MemType inside the block will make the HFileBlock complex and easy to write a bug, because we need to handle the shared & non-shared logics  at the same paths or methods.
   Separating them into two classes will be more clear.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services