Click here to Skip to main content
15,886,362 members
Please Sign up or sign in to vote.
3.00/5 (2 votes)
See more:
Hello Everybody,
I'm having a problem while the @RenderBody() method is being called in asp.net mvc3. The problem is that out of memory exception is being thrown while calling @RenderBody(). When the content view contains lesser data, it works perfectly but as the load is high, the exception is seen.

Thanks
Roman Raj Bajracharya
Posted
Comments
Jameel VM 4-Feb-13 7:53am    
Please post your code
ZurdoDev 4-Feb-13 8:07am    
If it only happens when the load is high, it may have nothing to do with your code, it may just be that your server does not have the resources.
Jameel VM 4-Feb-13 8:16am    
on what basis load is high?

1 solution

You have 1 of two situations occurring. I believe that the first is most likely based on your comment about the "load is high".
1) You are trying to process too much data. Perhaps your server doesn't have the resources to handle the volume data and requests that are coming through. Either you are using too many resources for each request, or you just have too many requests and the hardware can't handle them all.
2) You could get this error as well if an infinite loop scenario takes place. As it doesn't happen all the time, it would likely be related to recursive calls based on data values. In this scenario and row of data causes a recursive call to another row of data which in turn causes a call to the original row or itself to be called again and again recusively. Eventually, out of memory occurs.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900