commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ashok Madhavan <ashsud2...@yahoo.com>
Subject Re: Upload Problem
Date Wed, 11 Jun 2003 04:32:58 GMT
hi ROb,
I added the controller tag to the struts-config.xml
just after the <action-mappings>.
i added something like this :
<controller maxFileSize="2M" />

I then tried to add a 570K file and i still got the
same exception.
then i made the maxFileSize="-1". even then i was
getting the same exception.

Am i missing something major here.

regards
Ashok

--- Rob Leland <rleland@apache.org> wrote:
> Ashok Madhavan wrote:
> 
> Do you have a <controller > statement in your
> struts-config.xml and if 
> so are you setting
> the upload file size limit ? For example:
> 
>   <controller maxFileSize="2M" />
> 
> There are other parameters that can be set also.
> Another problem you may 
> run into is
> that if you are uploading really large files I have
> done 650MB and 1 GB 
> files with fileupload,
> and using tomcat there is a setting in the
> server.xml tomcat file that 
> prevents the session from timing out
> during file uploads.
> 
> -Rob
> 
> 
> >Hi all,
> >I am using the Struts version RC-1. 
> >
> >I am using the Struts upload and i am able to load
> >files upto about 230KB size. WHen the size of the
> >uploaded file goes more than 300KB, i am getting
> the
> >following exception.
> ><Jun 10, 2003 7:01:03 PM PDT> <Error> <HTTP>
> <101017>
>
><[ServletContext(id=5921274,name=prototype,context-path=/prototype)]
> >Root cause of ServletException
> >java.lang.NullPointerException
> >        at
>
>org.apache.commons.fileupload.DeferredFileOutputStream.thresholdReached(DeferredFileOutputStream.java:163)
> >        at
>
>org.apache.commons.fileupload.ThresholdingOutputStream.checkThreshold(ThresholdingOutputStream.java:260)
> >        at
>
>org.apache.commons.fileupload.ThresholdingOutputStream.write(ThresholdingOutputStream.java:167)
> >        at
>
>org.apache.commons.fileupload.MultipartStream.readBodyData(MultipartStream.java:513)
> >        at
>
>org.apache.commons.fileupload.FileUploadBase.parseRequest(FileUploadBase.java:360)
> >        at
>
>org.apache.struts.upload.CommonsMultipartRequestHandler.handleRequest(CommonsMultipartRequestHandler.java:233)
> >        at
>
>org.apache.struts.util.RequestUtils.populate(RequestUtils.java:1125)
> >        at
>
>org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:821)
> >        at
>
>org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:254)
> >        at
>
>org.apache.struts.action.ActionServlet.process(ActionServlet.java:1480)
> >        at
>
>org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:524)
> >        at
>
>javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
> >        at
>
>javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> >        at
>
>weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:1058)
> >        at
>
>weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:401)
> >        at
>
>weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:306)
> >        at
>
>weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:5445)
> >        at
>
>weblogic.security.service.SecurityServiceManager.runAs(SecurityServiceManager.java:780)
> >        at
>
>weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3105)
> >        at
>
>weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2588)
> >        at
>
>weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:213)
> >        at
>
>weblogic.kernel.ExecuteThread.run(ExecuteThread.java:189)
> >  
> >
> >
> >How do i fix this. 
> >Am i missing something.
> >
> >Regards
> >Ashok Madhavan
> >1
> >
>
>---------------------------------------------------------------------
> >To unsubscribe, e-mail:
> commons-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail:
> commons-user-help@jakarta.apache.org
> >
> >
> >
> >  
> >
> 
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail:
> commons-user-help@jakarta.apache.org
> 


Mime
View raw message