[
https://issues.apache.org/jira/browse/THRIFT-1065?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12995978#comment-12995978
]
Henrique Mendonca edited comment on THRIFT-1065 at 2/18/11 12:28 PM:
---------------------------------------------------------------------
e.g. if you remove any _throws_ declaration from ThriftTest.thrift:
_void testException(1: string arg) throws(1: Xception err1),_
*void testException(1: string arg),*
and call the service from the JS client side. The server throws then the
"unexpected" exception and I was getting something like:
{quote}
fname not defined
var ret = input.readStructBegin(fname)
{quote}
Now, with this patch, it should still throw the exception
(TApplicationException) on the JS client site
ps.: there is something wrong with the Java test server (trunk) I keep getting:
[java] Incoming content: [1,"testVoid",1,0,{}]
[java] Outgoing content:
Error:org/apache/thrift/server/ServerTestBase$TestHandler
is it just me?
was (Author: henrique):
e.g. if you remove the _throws_ declaration from ThriftTest.thrift:
_void testException(1: string arg) throws(1: Xception err1),_
*void testException(1: string arg),*
and run the JS test (which throws the _unexpected_ exception)
I get something like:
{quote}
fname not defined
var ret = input.readStructBegin(fname)
{quote}
> Unexpected exceptions not proper handled on JS
> ----------------------------------------------
>
> Key: THRIFT-1065
> URL: https://issues.apache.org/jira/browse/THRIFT-1065
> Project: Thrift
> Issue Type: Bug
> Components: JavaScript - Library
> Affects Versions: 0.6
> Reporter: Henrique Mendonca
> Priority: Minor
> Labels: javascript, thrift
> Fix For: 0.7
>
> Attachments: THRIFT-1065-read-undefined-exceptions2.patch
>
>
> Following THRIFT-550 and THRIFT-807:
> We still get JS errors when any undeclared exception is thrown (if not
> defined on the service IDL)
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira