Hello,
We have a case when UltraGrid consumes all available 10000 GDI objects in seconds and throws exception during repaint, which leads to red cross displayed instead of grid data. It is happening when we have columns with custom render controls assigned using UltraControlContainerEditor and Garbage Collector is in server mode.
I am attaching a zip archive with the sample application to reproduce the issue. It is modified example from C:\Users\Public\Documents\Infragistics\2015.2\Windows Forms\Samples\CS\Grid\EmbeddableEditors\ Only two files are modified: app.config and EmbeddableEditors.cs
To reproduce the issue, launch the application and simply move mouse over the grid for a couple of seconds. In Task Manager you will see how GDI objects count is growing and soon enough you will get an exception.
Any solutions for the issue? Or alternative approach of displaying custom data without consuming so much resources?
Thanks,
Andrei Marukovich
Hello Andrei,
Thank you for posting in our forum.
Can you please give more information related to your environment:
What is the operating system?
How much and what processors has the machine where this issue happens?
Looking forward to your reply.
Thank you for contacting Infragistics.
It is happening on 64-bit Windows 7, on various machines. For example on mine Dell Optiplex 990 with 16GB of memory and Intel Core i7-2600 @ 3.40 GHz. Hyper-threading is on so I have 8 logical cores.
Thank you for your feedback.
I have tested this scenario on my machine, Lenovo W510 with Intel Core i7 processor (same as your one) and successfully have reproduced it. However this is expected behavior as gcServer set to server mode should work only on multiprocessor system, e.g. machine with multiple physical processors and not a one with multiple logical processors. As both yours and mine machines are with single processor, setting the gcServer to server mode is not working. When I have set gcServer back to workstation mode the issue was solved.
Please check the following article in MSDN where it is described when you may use server mode of garbage collection https://msdn.microsoft.com/en-us/library/ms229357(v=vs.110).aspx .
Please let me know if you need any additional information.
Thank you for the answer, however I don't think this is an expected behavior. Server mode works both for multi-CPU and multi-core systems (and my PC has 4 cores). For example you can see a support article on Microsoft CRM about using server mode for multi-core systems - https://support.microsoft.com/en-us/kb/2489162
All the components of our application are more performant in the server mode, and only the grid prevents us from using it.
Andrei
I have investigated your issue further, and I have asked our engineering staff to examine this further. To ensure that it will receive attention, I have logged this behavior in our internal tracking system with a Development ID of #210365. So I’ve created a case for you CAS-167122-S7M2M9 and will update you for the progress of this issue via the mentioned case. You could reach your case following the link below:
https://www.infragistics.com/my-account/support-activity
Thank you for using Infragistics Components.