bugs.java.com
Bug ID: JDK-4267294 InputStream must be created in getInputStream...
The stream is already consumed when the second getInputStream() is executed. So I'm forced to write the stream to a temporary file (because it may not fit in a memory resident ByteArrayInputStream), and return a new InputStream object each time.