Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-1550

NPE when listing a file with no location

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Fixed
    • 0.22.0
    • 0.22.0
    • hdfs-client
    • None
    • Reviewed

    Description

      Lines listed below will caused a NullPointerException in DFSUtil.locatedBlocks2Locations (line 208) because EMPTY_BLOCK_LOCS will return null when calling blocks.getLocatedBlocks()

         /** a default LocatedBlocks object, its content should not be changed */
         private final static LocatedBlocks EMPTY_BLOCK_LOCS = new LocatedBlocks();
      

      Attachments

        1. nullLocatedBlocks.patch
          1 kB
          Hairong Kuang

        Activity

          People

            hairong Hairong Kuang
            hairong Hairong Kuang
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: