Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-21879 Read HFile's block to ByteBuffer directly instead of to byte for reducing young gc purpose
  3. HBASE-22090

The HFileBlock#CacheableDeserializer should pass ByteBuffAllocator to the newly created HFileBlock

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.0.0-alpha-1, 2.3.0
    • None
    • None
    • Reviewed

    Description

      In HBASE-22005, we have the following TODO in HFileBlock#CacheableDeserializer:

        public static final class BlockDeserializer implements CacheableDeserializer<Cacheable> {
          private BlockDeserializer() {
          }
      
          @Override
          public HFileBlock deserialize(ByteBuff buf, boolean reuse, MemoryType memType)
              throws IOException {
             // ....
      
            // TODO make the newly created HFileBlock use the off-heap allocator, Need change the
            // deserializer or change the deserialize interface.
            return new HFileBlock(newByteBuff, usesChecksum, memType, offset, nextBlockOnDiskSize, null,
                ByteBuffAllocator.HEAP);
          }
      

      Should use the global ByteBuffAllocator here rather than HEAP allocator, as the TODO said, we need to adjust the interface of deserializer.

      Attachments

        1. HBASE-22090.HBASE-21879.v03.patch
          27 kB
          Zheng Hu
        2. HBASE-22090.HBASE-21879.v02.patch
          26 kB
          Zheng Hu
        3. HBASE-22090.HBASE-21879.v01.patch
          26 kB
          Zheng Hu

        Issue Links

          Activity

            People

              openinx Zheng Hu
              openinx Zheng Hu
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: