Details
Description
In one of my handlers I throw a IllegalArgumentException if a SOAP header does not have a valid value. This then causes a SOAP Fault to be returned to the client (dynamic proxy).
When using the new LocalChanel (with a single extra thread) the following exception is returned as the piped stream is no longer open, although the client code does return the error message of the SOAP fault.
org.codehaus.xfire.XFireRuntimeException: Couldn't write stream.. Nested exception is org.codehaus.xfire.fault.XFireFault: Couldn't write message.
org.codehaus.xfire.fault.XFireFault: Couldn't write message.
at org.codehaus.xfire.soap.SoapSerializer.writeMessage(SoapSerializer.java:92)
at org.codehaus.xfire.transport.local.LocalChannel$1.run(LocalChannel.java:149)
at java.lang.Thread.run(Thread.java:534)
Caused by: com.ctc.wstx.exc.WstxIOException: Pipe closed
at com.ctc.wstx.sw.BaseStreamWriter.safeFlushStream(BaseStreamWriter.java:1439)
at com.ctc.wstx.sw.BaseStreamWriter.flush(BaseStreamWriter.java:313)
at org.codehaus.xfire.soap.SoapSerializer.writeMessage(SoapSerializer.java:88)
... 2 more
Caused by: java.io.IOException: Pipe closed
at java.io.PipedInputStream.receive(PipedInputStream.java:136)
at java.io.PipedInputStream.receive(PipedInputStream.java:176)
at java.io.PipedOutputStream.write(PipedOutputStream.java:129)
at sun.nio.cs.StreamEncoder$CharsetSE.writeBytes(StreamEncoder.java:336)
at sun.nio.cs.StreamEncoder$CharsetSE.implFlushBuffer(StreamEncoder.java:404)
at sun.nio.cs.StreamEncoder$CharsetSE.implFlush(StreamEncoder.java:408)
at sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:152)
at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:213)
at com.ctc.wstx.sw.BaseStreamWriter.flushStream(BaseStreamWriter.java:1430)
at com.ctc.wstx.sw.BaseStreamWriter.safeFlushStream(BaseStreamWriter.java:1437)
... 4 more
I tried using the debugger to get more details but as this is a timing related bug, when you step through the code you don't get the exception in the log
Paul
Activity
| Field | Original Value | New Value |
|---|---|---|
| Fix Version/s | 1.2.2 [ 12886 ] |
| Status | Open [ 1 ] | Closed [ 6 ] |
| Resolution | Fixed [ 1 ] |
I take it this worked fine before 1.2.1? I wonder whats going on here....