Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-5821

Incorrect handling of null value in Coprocessor aggregation function min()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.92.1
    • 0.92.2
    • Coprocessors
    • None
    • Reviewed

    Description

      Both in AggregateImplementation and AggregationClient, the evaluation of the current minimum value is like:
      min = (min == null || ci.compare(result, min) < 0) ? result : min;

      The LongColumnInterpreter takes null value is treated as the least value, while the above expression takes min as the greater value when it is null. Thus, the real minimum value gets discarded if a null value comes later.
      max() could also be wrong if a different ColumnInterpreter other than LongColumnInterpreter treats null value differently (as the greatest).

      Attachments

        1. HBASE-5821.patch
          2 kB
          Wei Xue

        Activity

          People

            maryannxue Wei Xue
            maryannxue Wei Xue
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: