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

HTable.getRow() returns null if the row does no exist

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 0.19.0, 0.19.1
    • 0.19.2, 0.20.0
    • Client, documentation
    • None
    • Fix API doc of HTable.getRow (non-existent row key returns null instead of empty RowResult)

    Description

      The HBase API docs says when the row does not exist, getRow() returns

      RowResult is empty if row does not exist.

      However, in regionserver/HRegionServer.java's getRow():

      if (result == null || result.isEmpty())
      return null;
      return new RowResult(row, result);

      It actually returns null. Either fix the code or the document.

      Attachments

        1. 1301.patch
          5 kB
          Rong-En Fan

        Issue Links

          Activity

            People

              rafan Rong-En Fan
              rafan Rong-En Fan
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: