axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Doug Davis <...@us.ibm.com>
Subject Re: Response message socket closed prematurely
Date Wed, 14 Aug 2002 12:53:10 GMT





FYI - related: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10585
-Dug


Russell Butek/Austin/IBM@IBMUS on 08/14/2002 08:38:46 AM

Please respond to axis-dev@xml.apache.org

To:    axis-dev@xml.apache.org
cc:
Subject:    Response message socket closed prematurely



Take the following code snippet from SimpleAxisWorker.run:

// ... snip... a bunch of out.writes
responseMsg.writeTo(out);
out.flush();
} catch (Exception e) {
log.debug(JavaUtils.getMessage("exception00"), e);
} finally {
try {
if (socket != null) socket.close();
} catch (Exception e) {
}
}

This is the code that writes the response message.  Note that, if there is
any problem writing this message, then the socket closes.  A potentially
common problem would be if a serializer fails.  The reason for the
serializer failure is never sent back to the client, so the client-side
AXIS engine, when it gets the socket closed exception, throws a very
uninformative exception:

<failure message="Remote Exception caught: (0)" type="junit.framework.
AssertionFailedError">junit.framework.AssertionFailedError: Remote
Exception caught: (0)
at test.wsdl.attachments.AttachmentTestCase.
test6AttachmentPortRPCInoutMimeMultipart(AttachmentTestCase.java:120)
</failure>

The server-side exception IS supposedly logged so perhaps we shouldn't
bother doing anything.  That's the miminal approach.  A better notion would
be for the client to at least get a useful message that the socket closed
prematurely.  The best notion, though I don't know how to do it
efficiently, would be for the real server-side exception to make its way to
the client.  Any opinions?  Thoughts about how to do the best notion?

Russell Butek
butek@us.ibm.com



Mime
View raw message