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

Avoid NPE in AsyncRequestFutureImpl#updateStats

VotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.0.0
    • 2.0.0
    • None
    • None
    • Reviewed

    Description

      If region disables the stats, it won’t response any ClientProtos.RegionLoadStats to client. So the NPE will happen in AsyncRequestFutureImpl#updateStats.
      We should use relevant log instead of NPE because the data manipulation shouldn’t be broken by statistics.

        protected void updateStats(ServerName server, Map<byte[], MultiResponse.RegionResult> results) {
            …
            ClientProtos.RegionLoadStats stat = regionStats.getValue().getStat();
            RegionLoadStats regionLoadstats = ProtobufUtil.createRegionLoadStats(stat);
            …
        }
      

      Attachments

        1. HBASE-16866.v1.patch
          1 kB
          Chia-Ping Tsai
        2. HBASE-16866.v0.patch
          1 kB
          Chia-Ping Tsai

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            chia7712 Chia-Ping Tsai
            chia7712 Chia-Ping Tsai
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment