I have been using jasper report server 5.6 community edition from last 6 months. while creating jasper PDF reports by using REST API the following type of error comes repeatedly after 40MB of file creation. i create those file in a loop by different parameters passing in the API. But regardless of number of pdf reports the "Heap space error" comes at around when the total sizes crosses 40MB. I have used all the combination of Heap space sizes, perm gen sizes, and classes like -XX:+CMSClassUnloadingEnabled -XX:+CMSPermGenSweepingEnabled Also i have used all the virtualizers(File, GZIP, Swap) with different parameters but no success. My server is a 64bit WINDOWS 2008 server edition with 32GB RAM The error comes like "Exception in thread "bitronix-task-scheduler" java.lang.OutOfMemoryError: Java" Kindly suggest.