Precisely - I am trying to "clean up my code" to optimize. The problem is that this report inherently uses a lot of memory - it basically displays the entire database if a user requests it. I am trying to accomplish this report without having to increase the memory. For example, is there a way to write the report directly to a file and not to memory? My preferred method would be to "stream" the report to the user without creating the entire report in memory and then serving it up to the user. I can't seem to find a way in Velocity to do either ("file" or return a "stream"). Any suggestions?
Main Topics
Browse All Topics





by: arevuriPosted on 2009-10-25 at 21:07:05ID: 25659609
There is no heap memory available to store your data. Increase the heap memory using JVM parameters for your tomcat. Check your cataline configuration files to set these value
Heap memory can be set using (This requires your system has sufficient RAM)
-Xms1024m indicates 1GB of minimum memory
-Xmx2048m indicates 2GB of maximum memory
This above parameters tells the JVM that how much memory of the machine should be allocated for your application.
Also you need to optimize your code not to store so much data in memory. Check if there is any duplicate data in mulitple objects. If so clean up the same.
-Revuri