[
http://jira.jboss.com/jira/browse/JBREM-543?page=comments#action_12339645 ]
John Mazzitelli commented on JBREM-543:
---------------------------------------
IMHO, this has to be changed back - at least to return an Exception message (if you want,
let the exception's message be that string). Ideally, have it configurable - let me
say whether I want the exception to be thrown, returned as an Exception or returned as a
String.
I just posted a comment to that forum link you provided.
My problem - in my code I don't know (nor do I want to know) what transport I'm
using. If you just return a String, how do I know this was an error that occurred? If I
am forced to look at the HTTP response code, that requires that my Client code know that
I'm using http or servlet transport. My client doesn't know what transport its
using - in fact, my customers can configure it anyway they want - they can use sslsocket,
socket, http, servlet, whatever they put in the config file. (BTW: this is one of the
great features of remoting - you actually don't even have to know how the messages are
getting transported! I just pass an opaque locator URL that I get from a config file and
connect my Client to it. I let remoting do everything for me - I just pass things in and
get things back from invoke.) Forcing me to examine the HTTP response code just to know
if the invocation failed or not breaks that separation.
fix servlet invoker error handling to be more like that of the http
invoker
---------------------------------------------------------------------------
Key: JBREM-543
URL:
http://jira.jboss.com/jira/browse/JBREM-543
Project: JBoss Remoting
Issue Type: Task
Security Level: Public(Everyone can see)
Affects Versions: 2.0.0.Beta2 (Boon)
Reporter: Tom Elrod
Assigned To: Tom Elrod
Fix For: 2.0.0.CR1 (Boon)
Need to change the servlet invoker so on client side will not throw an exception out of
the Client's invoke() method call, but just return the error (as text in most cases)
and have the response code indicate the error status code (e.g. 500). Although this is
not exactly how the http invoker handles exceptions from the http server invoker, is only
way to reliably get errors from web containers (like Tomcat).
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira