Last post Jun 08, 2009 02:00 AM by sumitd
Jun 07, 2009 03:03 AM|tharuraju|LINK
Jun 07, 2009 05:45 AM|HeartattacK|LINK
Memory refers to RAM and there may be a limitation on the amount of RAM your server can use. I'd recommend you create a form, save it to a database or the file system, dispose of resources and then create another form. I'm guessing all your forms are in
memory and if each form is 2MB in size, that makes 900 forms come to a whopping 1800MB. Is that much RAM available to a single request?
Jun 07, 2009 06:12 AM|sumitd|LINK
You can create 9000 pdf forms instead of 900, provided you close and destroy the object which is creating and holding pdf forms after each pdf creation. Create the object of the class which is creating .pdf form as late as possible and destroy it as soon
as .pdf get generated.
I believe you are not destroying the object after creation of .pdf. Post your code which is creating pdf forms.
Jun 07, 2009 11:03 PM|tharuraju|LINK
Jun 07, 2009 11:22 PM|HeartattacK|LINK
You can definitely use one object to create the forms - AS LONG AS THE FORMS THA ARE CREATED ARE NOT STORED IN MEMORY. What's happening is that the created forms are remaining in Server RAM and when the limit is reached, you get the exception. We can't tell
yo the details of the particular library you're using to create the pdfs, but you need to find out what it puts into RAM or even if it has memory leak issues. If you free the RAM that one form takes up before creating the next one, the problem should go away.
Jun 08, 2009 02:00 AM|sumitd|LINK
HeartAttack has explained your question quite well. If you have still doubt, do post it.