Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-15179 Cell/DBB end-to-end on the write-path
  3. HBASE-15787

Change the flush related heuristics to work with offheap size configured

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.0.0
    • regionserver
    • None
    • Reviewed

    Description

      With offheap MSLAB in place we may have to change the flush related heuristics to work with offheap size configured rather than the java heap size.
      Since we now have clear seperation of the memstore data size and memstore heap size, for offheap memstore
      -> Decide if the global.offheap.memstore.size is breached for blocking updates and force flushes.
      -> If the onheap global.memstore.size is breached (due to heap overhead) even then block updates and force flushes.
      -> The global.memstore.size.lower.limit is now by default 95% of the global.memstore.size. So now we apply this 95% on the global.offheap.memstore.size and also on global.memstore.size (as it was done for onheap case).
      -> We will have new FlushTypes introduced

        ABOVE_ONHEAP_LOWER_MARK, /* happens due to lower mark breach of onheap memstore settings
                                    An offheap memstore can even breach the onheap_lower_mark*/
        ABOVE_ONHEAP_HIGHER_MARK,/* happens due to higher mark breach of onheap memstore settings
                                    An offheap memstore can even breach the onheap_higher_mark*/
        ABOVE_OFFHEAP_LOWER_MARK,/* happens due to lower mark breach of offheap memstore settings*/
        ABOVE_OFFHEAP_HIGHER_MARK;
      

      -> regionServerAccounting does all the accounting.
      -> HeapMemoryTuner is what is litte tricky here. First thing to note is that at no point it will try to increase or decrease the global.offheap.memstore.size. If there is a heap pressure then it will try to increase the memstore heap limit.
      In case of offheap memstore there is always a chance that the heap pressure does not increase. In that case we could ideally decrease the heap limit for memstore. The current logic of heapmemory tuner is such that things will naturally settle down. But on discussion what we thought is let us include the flush count that happens due to offheap pressure but give that a lesser weightage and thus ensure that the initial decrease on memstore heap limit does not happen. Currently that fraction is set as 0.5.

      Attachments

        1. HBASE-15787.patch
          59 kB
          ramkrishna.s.vasudevan
        2. HBASE-15787_1.patch
          73 kB
          ramkrishna.s.vasudevan
        3. HBASE-15787_4.patch
          79 kB
          ramkrishna.s.vasudevan
        4. HBASE-15787_5.patch
          81 kB
          ramkrishna.s.vasudevan
        5. HBASE-15787_6.patch
          80 kB
          ramkrishna.s.vasudevan
        6. HBASE-15787_7.patch
          79 kB
          ramkrishna.s.vasudevan
        7. HBASE-15787_8.patch
          79 kB
          ramkrishna.s.vasudevan
        8. HBASE-15787_9.patch
          80 kB
          ramkrishna.s.vasudevan

        Issue Links

          Activity

            People

              ram_krish ramkrishna.s.vasudevan
              ram_krish ramkrishna.s.vasudevan
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: