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

DataStreamer.transfer() should timeout the socket InputStream.

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

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.8.0, 3.0.0-alpha1
    • hdfs-client
    • None
    • Reviewed

    Description

      While validating some HA failure modes we found that HDFS clients can take a long time to recover or sometimes don't recover at all since we don't setup the socket timeout in the InputStream:

      private void transfer () { ...
      ...
       OutputStream unbufOut = NetUtils.getOutputStream(sock, writeTimeout);
       InputStream unbufIn = NetUtils.getInputStream(sock);
      ...
      }
      

      The InputStream should have its own timeout in the same way as the OutputStream.

      Attachments

        1. 0001-HDFS-8311-DataStreamer.transfer-should-timeout-the-s.patch
          1 kB
          Esteban Gutierrez
        2. HDFS-8311.001.patch
          2 kB
          Esteban Gutierrez

        Issue Links

        Activity

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

          People

            esteban Esteban Gutierrez
            esteban Esteban Gutierrez
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment