There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • I setup an upload script under a JSP. I tested it by uploading a file via html form upload and it worked fine - the file was received. But when I tried uploading the file through a flash interface using the FileReference object I got a 500 error response. Flash's FileReference API was very vague, and I was unable to reproduce the error under another interface so I could see the error.... But I finnally did get something back by writing a catch and writing the error to a file. I don't know if this is accurate or not: "Stream ended unexpectedly" I do know that the error occurs when this line is ran: List items = upload.parseRequest(request); And here is some relevant code, but not all of it: (to show that I do have a factory set): DiskFileItemFactory factory = new DiskFileItemFactory(); factory.setSizeThreshold(524288000); ServletFileUpload upload = new ServletFileUpload(factory); upload.setSizeMax(524288000); List items = upload.parseRequest(request); I am fairly sure that flash is doing something that is throwing commons-fileupload off. But it does work with apache & php... The biggest difference in the headers, or at least the initial headers, is flash passes a "connection: close" header. When searching I came up with some vague answers. This page shows some comments at the bottom by users with similar problems: One guy posts a solution to fix the problem, but it seems like it is severely out of date because where it says "return items;" I do not see items declared in the function of the line he mentions. Plus he mentions line 336, and it's now on 800 something. Tried his suggestion but instead returned "true" and "false" (tried both ways) but it didn't work... Also when I tried his catch line ant said it was invalid, so I had to put "Exception e" instead. You may notice that his post is in all caps (posts after his appear to be for some reason). I did make sure to use the proper case (i do know of case sensitivity). With further reading I read instances where flash did a "test upload" without sending the file. In other cases I read something about it not sending to blank lines after the header. Not sure what my current problem is.... I'm sure once the problem is found, it should be fairly trivial to fix (i hope). Even though it may be flash's fault, it works in PHP and other instances... So it should work here :) Thanks in advance, -Luke
    via by Luke Scott,
    • org.apache.commons.fileupload.FileUploadBase$IOFileUploadException: Processing of multipart/form-data request failed. null at org.apache.commons.fileupload.FileUploadBase.parseRequest( at org.apache.commons.fileupload.servlet.ServletFileUpload.parseRequest( at ch.arpage.agora.util.MultiPartClassHandler.handleRequest( at org.apache.struts.util.RequestUtils.populate( at org.apache.struts.action.RequestProcessor.processPopulate( at org.apache.struts.action.RequestProcessor.process( at org.apache.struts.action.ActionServlet.process( at org.apache.struts.action.ActionServlet.doPost( at javax.servlet.http.HttpServlet.service( at javax.servlet.http.HttpServlet.service( at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( at org.apache.catalina.core.ApplicationFilterChain.doFilter( at ch.arpage.agora.util.strip.StripFilter.doFilter( at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( at org.apache.catalina.core.ApplicationFilterChain.doFilter( at ch.arpage.agora.util.compression.CompressionFilter.doFilter( at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( at org.apache.catalina.core.ApplicationFilterChain.doFilter( at org.apache.catalina.core.StandardWrapperValve.invoke( at org.apache.catalina.core.StandardContextValve.invoke( at org.apache.catalina.core.StandardHostValve.invoke( at org.apache.catalina.valves.ErrorReportValve.invoke( at org.apache.catalina.core.StandardEngineValve.invoke( at org.apache.catalina.connector.CoyoteAdapter.service( at org.apache.jk.server.JkCoyoteHandler.invoke( at org.apache.jk.common.HandlerRequest.invoke( at org.apache.jk.common.ChannelSocket.invoke( at org.apache.jk.common.ChannelSocket.processConnection( at org.apache.jk.common.ChannelSocket$SocketConnection.runIt( at org.apache.tomcat.util.threads.ThreadPool$ at Caused by: at org.apache.jk.common.JkInputStream.receive( at org.apache.jk.common.JkInputStream.refillReadBuffer( at org.apache.jk.common.JkInputStream.doRead( at org.apache.coyote.Request.doRead( at org.apache.catalina.connector.InputBuffer.realReadBytes( at org.apache.tomcat.util.buf.ByteChunk.substract( at at at org.apache.commons.fileupload.MultipartStream$ItemInputStream.makeAvailable( at org.apache.commons.fileupload.MultipartStream$ at at org.apache.commons.fileupload.util.Streams.copy( at org.apache.commons.fileupload.util.Streams.copy( at org.apache.commons.fileupload.FileUploadBase.parseRequest( ... 30 more

    Users with the same issue

    Unknown visitor1 times, last one,