I am using dhtmlxTree3.6. I have about 50,000 nodes in a level to render, so I use smart rendering.
I tested 50.000 nodes (json object) using smart rendering, it ran correctly. But when I scrolled the tree, the memory increased and won’t release. So if I scroll the tree frequently, the memory will become bigger and bigger, lead to memory leak.
I tested the sample [url]http://www.dhtmlx.com/docs/products/dhtmlxTree/samples/12_loading_processing_data/12_pro_smart_rendering.html[/url], it has the same problem.
Is there any way to fix this issue? Thanks.
There is no memory leak localy even on this online sample.
I test sample again. [url]http://www.dhtmlx.com/docs/products/dhtmlxTree/samples/12_loading_processing_data/12_pro_smart_rendering.html[/url]
browser: 27.0.1453.116 m
Scroll slowly until 1000 nodes which are placed on the top level all render. Attachment below is test result. Memory increased from 21M to 36M.
So my 50,000 nodes have more seriuos memory leak. How to fix it ? Thanks.
when you are scrolling tree, new nodes are rendered - so memory usage is increased. It is correct. There is not a memory leak.
I thought SmartRendering would remove DOM of nodes scrolled out of view. But I tested it just now and found that once the node is rendered, it’s DOM will always exist on the HTML page. So I guess the memory increases because of increasing DOM, right?
I test 10,000 nodes in top level and scroll all of them. Memory increased from 67M to 181M, a bit out of performance range. So if more nodes need to be build in a tree, I’m afraid performance will be the bottleneck. That would be better if SmartRendering could control memory properly and support large data.
Thank you for your reply.
So I guess the memory increases because of increasing DOM, right?
Yes, you are right.
That would be better if SmartRendering could control memory properly and support large data.
This is good idea. We will consider it. But it requires to rebuild Tree completely. Therefore, I’m not sure that such a modification will be possible.