You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Karen <ka...@gmail.com> on 2005/08/19 09:49:43 UTC

Set upload file size problem

According to the Upload component reference example, I can set max upload file 
size by add the below section into my xproject.application file.

<extension name="org.apache.tapestry.multipart-decoder"  
class="org.apache.tapestry.multipart.DefaultMultipartDecoder">
 	<configure property-name="maxSize" type="double" value="134217728"/>
</extension>

However, after i've added it into the .application file, and do a re-deploy of 
my webapp, when I do an upload of 14MB file, it thrown me the 
org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException. Have 
I miss anything in order to set the allow upload file size? 

Regards,
K.

On Friday 19 August 2005 13:51, Karen wrote:
> Actually I did it in the form listener. However, the exception was thrown
> before the request hit page begin render. Hence, even i put a catch block
> in my listener, is of no use.
>
> Any idea?
>
> K.
>
> On Friday 19 August 2005 12:05, Patrick Casey wrote:
> > 	What happens when you try to catch it in the submit listener? Does
> > your catch block not run? Or are you trying to redirect directly from
> > there?
> >
> > 	If memory serves, if you want to navigate via cycle.activate() you
> > have to do it in the form listener method, not the submit button's
> > listener message.
> >
> > 	Altnerately, did you try catching the applicaitonruntimeexception
> > and re-throwing a PageRedirectException?
> >
> > 	--- Pat
> >
> > > -----Original Message-----
> > > From: Karen [mailto:karenlyakbilling@gmail.com]
> > > Sent: Thursday, August 18, 2005 8:48 PM
> > > To: 'Tapestry users'
> > > Subject: File upload size problem
> > >
> > > Hi,
> > >
> > > I'm using Tapestry's Upload component to upload files. It throws
> > > org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException
> > > when
> > > the upload file size exceed the allow range. What I need to do is to
> > > turn that exception to a more meaningful message before display to the
> > > HTML page.
> > >
> > > I tried to catch the ApplicationRuntimeException from the submit
> > > listener's
> > > method, but to no avail.
> > >
> > > How to catch the ApplicationRuntimeException when this happen? Please
> > > advise.
> > >
> > > Thank you.
> > >
> > > Regards,
> > > Karen
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org