When working with the diagramming models, I am seeing performance issues when loading a number of nodes I would consider to be a small number. I am bringing content into each of the nodes and then displaying them on the diagram. However, when loading 48 nodes with content, the diagram is taking 25+ seconds to display. As my diagrams could contain 100-200 nodes, this seems to be a very low number to be seeing a performance issue. I have validated that the time to read and load the content to the nodes is less than 2 seconds.
I also looked into using the Virtualization setting to see if this would improve the performance. If the diagram is zoomed in to show 1-3 nodes, the load time is about 10 seconds. However, as I navigate the diagram, the solution crashes. The errors seen in the debugger are below. Note that this did not occur when I did not use Virtualization.
Any thoughts on improving the performance for my diagrams?
Errors from debugger:
Hi Stephen ,
Reported issue: Performance issue while loading a greater number of nodes in diagram and application crash while using Virtualization
We need know below details from your side. So that we can reproduce the exact issue from our side that you are facing,
Regards,
Deepa Thiruppathy
As an initial response to the above, the issue I'm seeing is on opening an existing diagram from the xml file. I have saved the nodes and connectors along with several custom attributes. I am reloading the nodes with content through the OnItemAdded event of the diagram. I am not adjusting the layout during the opening of the file and loading of the nodes and connectors.
Please see the answers to the questions below:
We are trying to create a sample as you explained. We will share you the more details on or before May 26, 2022.
Hi Stephen,
Reported issue: Performance issue when loading 200 nodes and connectors.
We have created a sample and validated the performance with 100 nodes and 150 nodes. When loading 100 nodes it takes less than 5 seconds and it takes less than 7 seconds for 150 nodes. We have loaded the pre-saved xaml file into diagram as a stream file at run time. We have content and content template for nodes and Content for nodes will be added from ItemAddedEvent during run time.
Sample link: https://www.syncfusion.com/downloads/support/directtrac/general/ze/PerformanceValidationSample-2108328770
We request you to load your xaml file in above sample. If you are still facing the issue, please share your xaml file with us. We will validate it from our side. If you have any confidential information in xaml file and if you are not interested to share, please explain content, and content template related details with us. We will try to add duplicate content and content template as your details. If you are not okay to share those details in the forum, We request you create a ticket using below link,
Link: Create Ticket | Syncfusion Support
Regards,
Deepa Thiruppathy