[jboss-jira] [JBoss JIRA] Commented: (JBREM-635) Remove misleading error message from HTTPUnMarshaller.
Ron Sigal (JIRA)
jira-events at jboss.com
Thu Dec 7 16:54:55 EST 2006
[ http://jira.jboss.com/jira/browse/JBREM-635?page=comments#action_12348331 ]
Ron Sigal commented on JBREM-635:
---------------------------------
Removing the try/catch revealed two other issues.
1) Messages with no body don't need a content-type header, which currently causes isBinaryData() to throw an exception. isBinaryData() has been changed to return false in the absence of a content-type header. read() goes on to read 0 bytes and return null.
2) It is also possible for messages with no content to have a content-type such that isBinaryData() returns true. (E.g., org.jboss.test.remoting.transport.http.method.HTTPInvokerTestClient.testOptionsInvocation() sends an OPTIONS message with no body and content-type application/octet-stream.) But then super.read() may throw an EOFException. read() has been changed to return null in the event of an EOFException.
> Remove misleading error message from HTTPUnMarshaller.
> ------------------------------------------------------
>
> Key: JBREM-635
> URL: http://jira.jboss.com/jira/browse/JBREM-635
> Project: JBoss Remoting
> Issue Type: Task
> Security Level: Public(Everyone can see)
> Affects Versions: 2.2.0.Beta1 (Bluto)
> Reporter: Ron Sigal
> Assigned To: Ron Sigal
> Priority: Minor
> Fix For: 2.2.0.Beta1 (Bluto)
>
>
> In read() the code
> try
> {
> if (isBinaryData(metadata))
> return super.read(inputStream, metadata);
> }
> catch (Exception e)
> {
> log.warn("Can not get Content-Type from header for http unmarshalling.");
> }
> can return a warning about content-type even if the exception is thrown by super.read().
--
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
More information about the jboss-jira
mailing list