|
From: ujay68 <uj...@gm...> - 2011-05-18 14:24:51
|
Maybe I'm a little closer to an explanation: the org.jboss.resteasy.plugins.providers.DataSourceProvider#readDataSource method <http://resteasy.svn.sourceforge.net/viewvc/resteasy/trunk/jaxrs/resteasy-jaxrs/src/main/java/org/jboss/resteasy/plugins/providers/DataSourceProvider.java?revision=1349&view=markup> first tries to read 4096 bytes from the given stream, then checks in.available() to decide if there is more to write to a temp file. This is wrong, because java.io.InputStream.available only returns a guess if there are more bytes available. Here, the given InputStream ist a java.io.SequenceInputStream that returns 0 after the first chunk even if more chunks with more bytes are available. The readDataSourceMethod must continue reading until EOF. I'll add an issue to the bug tracker: https://issues.jboss.org/browse/RESTEASY-545 Regards, Jay |