commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Manish Agrawal" <>
Subject [FileUpload] File upload giving error: Stream ended unexpectedly
Date Mon, 27 Mar 2006 11:21:42 GMT

I have a web applications using sturts framework. The application allow
users to upload data files on server. The application is running on Apache
Tomcat 5.0 server. I am using Commons File Upload 1.0 for uploading files.

The application is running fine but sometime it fails to upload files and
gives the following error:

Mar 27, 2006 2:31:17 AM
org.apache.struts.upload.CommonsMultipartRequestHandler handleRequest
SEVERE: Failed to parse multipart request
org.apache.commons.fileupload.FileUploadException: Processing of
multipart/form-data request failed. Stream ended unexpectedly
        at org.apache.commons.fileupload.FileUploadBase.parseRequest (
        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( :157)
        at org.apache.catalina.core.StandardWrapperValve.invoke(
        at org.apache.catalina.core.StandardValveContext.invokeNext(
        at org.apache.catalina.core.StandardPipeline.invoke (
        at org.apache.catalina.core.StandardContextValve.invokeInternal(
        at org.apache.catalina.core.StandardContextValve.invoke( :152)
        at org.apache.catalina.core.StandardValveContext.invokeNext(
        at org.apache.catalina.core.StandardPipeline.invoke(
        at org.apache.catalina.core.StandardHostValve.invoke (
        at org.apache.catalina.core.StandardValveContext.invokeNext(
        at org.apache.catalina.valves.ErrorReportValve.invoke(
        at org.apache.catalina.core.StandardValveContext.invokeNext(
        at org.apache.catalina.valves.AccessLogValve.invoke(
        at org.apache.catalina.core.StandardValveContext.invokeNext (
        at org.apache.catalina.core.StandardPipeline.invoke(
        at org.apache.catalina.core.StandardEngineValve.invoke(
        at org.apache.catalina.core.StandardValveContext.invokeNext(
        at org.apache.catalina.core.StandardPipeline.invoke(
        at org.apache.catalina.core.ContainerBase.invoke (
        at org.apache.coyote.tomcat5.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.SocketConnection.runIt (
        at org.apache.tomcat.util.threads.ThreadPool$

The behaviour of application is random, sometime it works fine and sometime
not. I initially thought it's happening when there are many people trying to
upload at the same time. But it's giving error even when only one user is
trying to upload.

When I restart my server it started working fine, I suspect it is throwing
error after uploading certain number of file or certain bytes of data. I am
not sure if it possible. Please let me know if there are any pointers which
could help me debug the problem further.

The server is configured to upload large files, so that's not a problem.


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message