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

Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 2.7.0
    • None
    • None
    • Reviewed

    Description

      The synchronized for HdfsDataInputStream#getAllBlocks and FSDataInputStream#seek are unnecessary.

      Attachments

        1. HDFS-7741.001.patch
          1 kB
          Yi Liu

        Issue Links

          Activity

            cmccabe Colin McCabe added a comment -

            +1 pending jenkins. The locking on the wrapper streams adds nothing here, since we lock inside DFSInputStream. Thanks, Yi.

            cmccabe Colin McCabe added a comment - +1 pending jenkins. The locking on the wrapper streams adds nothing here, since we lock inside DFSInputStream. Thanks, Yi.
            hadoopqa Hadoop QA added a comment -

            -1 overall. Here are the results of testing the latest attachment
            http://issues.apache.org/jira/secure/attachment/12696930/HDFS-7741.001.patch
            against trunk revision 6583ad1.

            +1 @author. The patch does not contain any @author tags.

            -1 tests included. The patch doesn't appear to include any new or modified tests.
            Please justify why no new tests are needed for this patch.
            Also please list what manual steps were performed to verify this patch.

            +1 javac. The applied patch does not increase the total number of javac compiler warnings.

            +1 javadoc. There were no new javadoc warning messages.

            +1 eclipse:eclipse. The patch built with eclipse:eclipse.

            +1 findbugs. The patch does not introduce any new Findbugs (version 2.0.3) warnings.

            +1 release audit. The applied patch does not increase the total number of release audit warnings.

            +1 core tests. The patch passed unit tests in hadoop-common-project/hadoop-common hadoop-hdfs-project/hadoop-hdfs.

            Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/9450//testReport/
            Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/9450//console

            This message is automatically generated.

            hadoopqa Hadoop QA added a comment - -1 overall . Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12696930/HDFS-7741.001.patch against trunk revision 6583ad1. +1 @author . The patch does not contain any @author tags. -1 tests included . The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 javac . The applied patch does not increase the total number of javac compiler warnings. +1 javadoc . There were no new javadoc warning messages. +1 eclipse:eclipse . The patch built with eclipse:eclipse. +1 findbugs . The patch does not introduce any new Findbugs (version 2.0.3) warnings. +1 release audit . The applied patch does not increase the total number of release audit warnings. +1 core tests . The patch passed unit tests in hadoop-common-project/hadoop-common hadoop-hdfs-project/hadoop-hdfs. Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/9450//testReport/ Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/9450//console This message is automatically generated.
            hitliuyi Yi Liu added a comment -

            Thanks Colin for review.

            hitliuyi Yi Liu added a comment - Thanks Colin for review.
            hitliuyi Yi Liu added a comment -

            Committed to trunk and branch-2.

            hitliuyi Yi Liu added a comment - Committed to trunk and branch-2.
            hudson Hudson added a comment -

            FAILURE: Integrated in Hadoop-trunk-Commit #7036 (See https://builds.apache.org/job/Hadoop-trunk-Commit/7036/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            hudson Hudson added a comment - FAILURE: Integrated in Hadoop-trunk-Commit #7036 (See https://builds.apache.org/job/Hadoop-trunk-Commit/7036/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            hudson Hudson added a comment -

            FAILURE: Integrated in Hadoop-Yarn-trunk-Java8 #96 (See https://builds.apache.org/job/Hadoop-Yarn-trunk-Java8/96/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Yarn-trunk-Java8 #96 (See https://builds.apache.org/job/Hadoop-Yarn-trunk-Java8/96/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            hudson Hudson added a comment -

            FAILURE: Integrated in Hadoop-Yarn-trunk #830 (See https://builds.apache.org/job/Hadoop-Yarn-trunk/830/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Yarn-trunk #830 (See https://builds.apache.org/job/Hadoop-Yarn-trunk/830/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            hudson Hudson added a comment -

            FAILURE: Integrated in Hadoop-Hdfs-trunk-Java8 #93 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Java8/93/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Hdfs-trunk-Java8 #93 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Java8/93/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            hudson Hudson added a comment -

            SUCCESS: Integrated in Hadoop-Hdfs-trunk #2028 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/2028/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            hudson Hudson added a comment - SUCCESS: Integrated in Hadoop-Hdfs-trunk #2028 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/2028/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            hudson Hudson added a comment -

            FAILURE: Integrated in Hadoop-Mapreduce-trunk-Java8 #97 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Java8/97/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Mapreduce-trunk-Java8 #97 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Java8/97/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            hudson Hudson added a comment -

            FAILURE: Integrated in Hadoop-Mapreduce-trunk #2047 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/2047/)
            HDFS-7741. Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9)

            • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java
            • hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
            hudson Hudson added a comment - FAILURE: Integrated in Hadoop-Mapreduce-trunk #2047 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/2047/ ) HDFS-7741 . Remove unnecessary synchronized in FSDataInputStream and HdfsDataInputStream. (yliu) (yliu: rev 7b10ef0c3bfec9cdf20d6e2385b6d218809a37b9) hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/client/HdfsDataInputStream.java hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt

            People

              hitliuyi Yi Liu
              hitliuyi Yi Liu
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: