[ 
https://issues.apache.org/jira/browse/HDFS-1076?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Doug Cutting updated HDFS-1076:
-------------------------------

    Attachment: HDFS-1076.patch

The problem is that currently the exceptions declared in the interface are not 
actually thrown to the client, and the test code has been written to rely on 
the behavior of the RemoteException wrapper.

We could:
 - Change the tests to not require the exception name in the error string.  
This may break applications that depend on the exception name in the error 
string.  Is that an important compatibility feature?
 - Change FsShell so that it always includes exception names in error strings, 
not just for RemoteException.  That would also break some tests, as not all 
error messages currently contain the exception name.
 - Change Avro reflect RPC so that thrown exceptions modify their message 
string to contain their name.  This seems like the wrong long-term direction.  
Remotely thrown exceptions should appear locally identically to the same 
exception thrown locally.

Here's a patch that takes the first approach.  It also updates Avro to 1.3.2, 
which propagates the correct error string.

> HFDS CLI error tests fail with Avro RPC
> ---------------------------------------
>
>                 Key: HDFS-1076
>                 URL: https://issues.apache.org/jira/browse/HDFS-1076
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: test
>            Reporter: Doug Cutting
>            Assignee: Doug Cutting
>             Fix For: 0.22.0
>
>         Attachments: HDFS-1076.patch
>
>
> Some HDFS command-line tests (TestHDFSCLI) fail when using AvroRpcEngine 
> because the error string does not match.  Calling getMessage() on a remote 
> exception thrown by WritableRpcEngine produces a string that contains the 
> exception name followed by its getMessage(), while exceptions thrown by 
> AvroRpcEngine contain just the getMessage() string of the original exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to