Is there a way to solve the 'out of memory' error?
Is there a way to solve the 'out of memory' error?
sol
Posts: 18Questions: 7Answers: 0
Hi, all.
I have a problem with out of memory, and I am wondering what way there will be in my development environment.
First, I should use scroll X and scroll Y. So, I cannot set paging-option false.
Second, I'm using ajax data. Data length is over 4,000. (over 100MB)
Is there a way to handle this error in this situation?
Answers
That's not many records, so that shouldn't be a problem. We're happy to take a look, but as per the forum rules, please link to a test case - a test case that replicates the issue will ensure you'll get a quick and accurate response. Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.
Colin
Hi, colin!
I'm not able to link my page.. so I made the test case.
but..
actually, this is all.. (And I wrote question wrong.. I mean '** So, I can't set paging-option true' )
I searched Forums(I read question1 and question2 ), and I found the way to use 'serverSide' rendering and 'deferRender' options.
If not using pagination, are these the only way to fix this error?
I want to limit the using memory, is this available?
It works fine here, so there must be something else going on with your config. A few questions might help understand what's happening. What makes you think it's DataTables that's causing the memory issues? Have you tried a default config (with those three options commented out)?
Could you look at that, please, and see if it helps. If it's still not working for you, please can you update my example, or link to your page, so that we can see the problem.
Colin
Colin, thanks for your comment.
I edited your test page, here
And I don't know the exact situation, but out of memory also appeared once on this page when I edit the code.
Enable
deferRender
andpaging
which will help reduce memory usage in your example there. You are displaying all of the table cells at once, so it is going to be slow and maximally memory intensive for that data.If you are getting a memory error with that example (I'm not, but I don't know what host computer you are using; RAM, browser, etc) then it suggests to me that your computer doesn't have a huge amount of RAM. There is no memory leak on that page.
Allan