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

FileInputStream leak on failure path in BlockSender

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.0-alpha2
    • Fix Version/s: 2.9.0, 3.0.0-alpha2
    • Component/s: datanode
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      The BlockSender constructor should close the blockIn and checksumIn streams here:

      405:       blockIn = datanode.data.getBlockInputStream(block, offset); // seek to offset
      406:       ris = new ReplicaInputStreams(
      407:           blockIn, checksumIn, volumeRef, fileIoProvider);
      408:     } catch (IOException ioe) {
      409:       IOUtils.closeStream(this);
      410:       throw ioe;
      411:     }
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                arpitagarwal Arpit Agarwal
                Reporter:
                arpitagarwal Arpit Agarwal
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: