Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.20.205.0
    • Fix Version/s: 0.23.0, 0.24.0, 1.0.0
    • Component/s: webhdfs
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      PUT Request: http://localhost:50070/webhdfs/some_path?op=MKDIRS&permission=955

      Exception returned

      HTTP/1.1 500 Internal Server Error
      {"RemoteException":{"className":"com.sun.jersey.api.ParamException$QueryParamException","message":"java.lang.NumberFormatException: For input string: \"955\""}}

      We should return a 400 with appropriate error message

      1. h2428_20111011.patch
        3 kB
        Tsz Wo Nicholas Sze
      2. h2428_20111011_0.20s.patch
        3 kB
        Tsz Wo Nicholas Sze

        Activity

        Hide
        Hudson added a comment -

        Integrated in Hadoop-Mapreduce-0.23-Build #64 (See https://builds.apache.org/job/Hadoop-Mapreduce-0.23-Build/64/)
        svn merge -c 1183098 from trunk for HDFS-2428.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486
        Files :

        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Mapreduce-0.23-Build #64 (See https://builds.apache.org/job/Hadoop-Mapreduce-0.23-Build/64/ ) svn merge -c 1183098 from trunk for HDFS-2428 . szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486 Files : /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Hdfs-0.23-Build #52 (See https://builds.apache.org/job/Hadoop-Hdfs-0.23-Build/52/)
        svn merge -c 1183098 from trunk for HDFS-2428.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486
        Files :

        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Hdfs-0.23-Build #52 (See https://builds.apache.org/job/Hadoop-Hdfs-0.23-Build/52/ ) svn merge -c 1183098 from trunk for HDFS-2428 . szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486 Files : /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Mapreduce-0.23-Commit #60 (See https://builds.apache.org/job/Hadoop-Mapreduce-0.23-Commit/60/)
        svn merge -c 1183098 from trunk for HDFS-2428.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486
        Files :

        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Mapreduce-0.23-Commit #60 (See https://builds.apache.org/job/Hadoop-Mapreduce-0.23-Commit/60/ ) svn merge -c 1183098 from trunk for HDFS-2428 . szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486 Files : /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Hdfs-0.23-Commit #65 (See https://builds.apache.org/job/Hadoop-Hdfs-0.23-Commit/65/)
        svn merge -c 1183098 from trunk for HDFS-2428.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486
        Files :

        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Hdfs-0.23-Commit #65 (See https://builds.apache.org/job/Hadoop-Hdfs-0.23-Commit/65/ ) svn merge -c 1183098 from trunk for HDFS-2428 . szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486 Files : /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Common-0.23-Commit #64 (See https://builds.apache.org/job/Hadoop-Common-0.23-Commit/64/)
        svn merge -c 1183098 from trunk for HDFS-2428.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486
        Files :

        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Common-0.23-Commit #64 (See https://builds.apache.org/job/Hadoop-Common-0.23-Commit/64/ ) svn merge -c 1183098 from trunk for HDFS-2428 . szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1189486 Files : /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/branches/branch-0.23/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Tsz Wo Nicholas Sze added a comment -

        Merged to 0.23.

        Show
        Tsz Wo Nicholas Sze added a comment - Merged to 0.23.
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Mapreduce-trunk #860 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/860/)
        HDFS-2428. Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098
        Files :

        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Mapreduce-trunk #860 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk/860/ ) HDFS-2428 . Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs. szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Hdfs-trunk #830 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/830/)
        HDFS-2428. Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098
        Files :

        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Hdfs-trunk #830 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk/830/ ) HDFS-2428 . Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs. szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Mapreduce-trunk-Commit #1093 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Commit/1093/)
        HDFS-2428. Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098
        Files :

        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Mapreduce-trunk-Commit #1093 (See https://builds.apache.org/job/Hadoop-Mapreduce-trunk-Commit/1093/ ) HDFS-2428 . Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs. szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Tsz Wo Nicholas Sze added a comment -

        Thanks Suresh for the review.

        I have committed this.

        Show
        Tsz Wo Nicholas Sze added a comment - Thanks Suresh for the review. I have committed this.
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Hdfs-trunk-Commit #1152 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Commit/1152/)
        HDFS-2428. Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098
        Files :

        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Hdfs-trunk-Commit #1152 (See https://builds.apache.org/job/Hadoop-Hdfs-trunk-Commit/1152/ ) HDFS-2428 . Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs. szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Common-trunk-Commit #1074 (See https://builds.apache.org/job/Hadoop-Common-trunk-Commit/1074/)
        HDFS-2428. Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs.

        szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098
        Files :

        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java
        • /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Show
        Hudson added a comment - Integrated in Hadoop-Common-trunk-Commit #1074 (See https://builds.apache.org/job/Hadoop-Common-trunk-Commit/1074/ ) HDFS-2428 . Convert com.sun.jersey.api.ParamException$QueryParamException to IllegalArgumentException and response it http BAD_REQUEST in webhdfs. szetszwo : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1183098 Files : /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/JsonUtil.java /hadoop/common/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/web/resources/ExceptionHandler.java
        Hide
        Suresh Srinivas added a comment -

        + for the patch.

        Show
        Suresh Srinivas added a comment - + for the patch.
        Hide
        Tsz Wo Nicholas Sze added a comment -

        Manually tested it.

        $curl -i -X PUT -L "http://localhost:50070/webhdfs/foo/a.patch?op=CREATE&permission=955&overwrite=false&bufferSize=4096&blockSize=33554432&user.name=szetszwo" -T a.patch
        HTTP/1.1 100 Continue
        
        HTTP/1.1 400 Bad Request
        Content-Type: text/html; charset=utf-8
        Expires: Thu, 01-Jan-1970 00:00:00 GMT
        Set-Cookie: hadoop.auth="u=szetszwo&p=szetszwo&t=simple&e=1318482179911&s=wOzQ4NVX5TtJXUfKSdQ4n/jAjJg=";Path=/
        Content-Type: application/json
        Transfer-Encoding: chunked
        Server: Jetty(6.1.26)
        
        {"RemoteException":{"exception":"IllegalArgumentException","javaClassName":"java.lang.IllegalArgumentException",
        "message":"Invalid value for webhdfs parameter \"permission\": For input string: \"955\""}}
        
        Show
        Tsz Wo Nicholas Sze added a comment - Manually tested it. $curl -i -X PUT -L "http://localhost:50070/webhdfs/foo/a.patch?op=CREATE&permission=955&overwrite=false&bufferSize=4096&blockSize=33554432&user.name=szetszwo" -T a.patch HTTP/1.1 100 Continue HTTP/1.1 400 Bad Request Content-Type: text/html; charset=utf-8 Expires: Thu, 01-Jan-1970 00:00:00 GMT Set-Cookie: hadoop.auth="u=szetszwo&p=szetszwo&t=simple&e=1318482179911&s=wOzQ4NVX5TtJXUfKSdQ4n/jAjJg=";Path=/ Content-Type: application/json Transfer-Encoding: chunked Server: Jetty(6.1.26) {"RemoteException":{"exception":"IllegalArgumentException","javaClassName":"java.lang.IllegalArgumentException", "message":"Invalid value for webhdfs parameter \"permission\": For input string: \"955\""}}
        Hide
        Hadoop QA added a comment -

        -1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12498698/h2428_20111011.patch
        against trunk revision .

        +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 javadoc. The javadoc tool did not generate any warning messages.

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

        +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) 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 .

        +1 contrib tests. The patch passed contrib unit tests.

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

        This message is automatically generated.

        Show
        Hadoop QA added a comment - -1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12498698/h2428_20111011.patch against trunk revision . +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 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) 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 . +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-HDFS-Build/1361//testReport/ Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/1361//console This message is automatically generated.
        Hide
        Tsz Wo Nicholas Sze added a comment -

        The file attached was incorrect. Should be this.

        Show
        Tsz Wo Nicholas Sze added a comment - The file attached was incorrect. Should be this.
        Hide
        Tsz Wo Nicholas Sze added a comment -

        h2428_20111011_0.20s.patch
        h2428_20111011.patch

        Convert jersey ParamException to IllegalArgumentException and use 400 for IllegalArgumentException.

        Show
        Tsz Wo Nicholas Sze added a comment - h2428_20111011_0.20s.patch h2428_20111011.patch Convert jersey ParamException to IllegalArgumentException and use 400 for IllegalArgumentException.
        Hide
        Arpit Gupta added a comment -

        Rename request leads to a 500 when the dstPath is null. We should return a 400

        Request URI http://NN:50070/webhdfs/tmp/webhdfs_data/dir_with_children_to_be_renamed?op=RENAME&dstPath=
        Request Method: PUT
        Status Line: HTTP/1.1 500 Internal Server Error
        Response Content: {"RemoteException":{"className":"java.lang.IllegalArgumentException","message":"Can not create a Path from a null string"}}
        

        The content is correct but we should return a 400 instead of a 500

        Show
        Arpit Gupta added a comment - Rename request leads to a 500 when the dstPath is null. We should return a 400 Request URI http: //NN:50070/webhdfs/tmp/webhdfs_data/dir_with_children_to_be_renamed?op=RENAME&dstPath= Request Method: PUT Status Line: HTTP/1.1 500 Internal Server Error Response Content: { "RemoteException" :{ "className" : "java.lang.IllegalArgumentException" , "message" : "Can not create a Path from a null string" }} The content is correct but we should return a 400 instead of a 500
        Hide
        Arpit Gupta added a comment -

        Same issue can be seen for a different call invalid value for recursive is sent.

        Request URI http://BB:50070/webhdfs/path?op=DELETE&recursive=invalid
        Request Method: DELETE
        HTTP/1.1 500 Internal Server Error
        Request Content: {"RemoteException":

        {"className":"com.sun.jersey.api.ParamException$QueryParamException","message":"java.lang.IllegalArgumentException: Failed to parse \"invalid\" to Boolean."}

        }

        Show
        Arpit Gupta added a comment - Same issue can be seen for a different call invalid value for recursive is sent. Request URI http://BB:50070/webhdfs/path?op=DELETE&recursive=invalid Request Method: DELETE HTTP/1.1 500 Internal Server Error Request Content: {"RemoteException": {"className":"com.sun.jersey.api.ParamException$QueryParamException","message":"java.lang.IllegalArgumentException: Failed to parse \"invalid\" to Boolean."} }

          People

          • Assignee:
            Tsz Wo Nicholas Sze
            Reporter:
            Arpit Gupta
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development