You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Vijay Kandy <Vi...@mailcode.com> on 2003/09/12 17:36:37 UTC

Generating huge reports via servlets

Hello All,

I have a servlet that generates reports in CSV format. When the content size
of the report is small, it works fine. But if the content size is 4MB, I get
a 404 error but no exceptions. I tried setBufferSize(4MB) and contentSize to
the actual size of the report but that didnt help much. I am running Tomcat
4.1.27. Please help.

Vijay

Re: Generating huge reports via servlets

Posted by Ben Souther <bp...@adelphia.net>.
Is it the size of the file or the amount of time that it takes to generate 
it?. Try serving up a static copy of the report after it's finished.
If you can serve up a static version, then it's probably not the size.

We've got some large reports (>5meg) that can take up to 15 minutes to 
generate. Instead of having the user sit at a blank screen while it's being 
run, we kick off the report and immeditately forward the context to a 
status JSP.  The status page refereshes every 20 seconds, checking to see 
what reports are complete.  Once complete, we provide a link to a servlet 
that streams the report to the user's browser.



On Friday 12 September 2003 11:36 am, you wrote:
> Hello All,
>
> I have a servlet that generates reports in CSV format. When the content
> size of the report is small, it works fine. But if the content size is 4MB,
> I get a 404 error but no exceptions. I tried setBufferSize(4MB) and
> contentSize to the actual size of the report but that didnt help much. I am
> running Tomcat 4.1.27. Please help.
>
> Vijay
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org

Re: Generating huge reports via servlets

Posted by Anton Tagunov <at...@mail.cnt.ru>.
Hello Vijay!

VK> I have a servlet that generates reports in CSV format. When the content size
VK> of the report is small, it works fine. But if the content size is 4MB, I get
VK> a 404 error but no exceptions. I tried setBufferSize(4MB) and contentSize to
VK> the actual size of the report but that didnt help much. I am running Tomcat
VK> 4.1.27.

Try looking through your logs. Is there anything to help you?

(When Tomcat is down kill all your logs, then start Tomcat, reproduce
the error and examine all you have in the logs dir. After this you'll
know where to look for errors.)

Anton