Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
2732
UltraGridExcelEporter (async) export performance
posted

Hello,

I have a small question regarding a performance difference between using the export function and the async export function on the UltraGridExcelExporter (version 11.2.20112.1010).
I noticed that when using the export function its up to 3 times faster than using the async export.

A simple example that exports 54539 rows is included, as you will see:
- export takes up to 94852 milliseconds
- async export takes up to 325792 milliseconds

I noticed the cpu only takes up to a third of its total "power" when using async export; which explains the difference in timings.
But my question is: why does the async export only uses a third of the cpu resources available?

We would like to use async export but if it's that much slower we are "forced" to use the normal export functionalities.

Thanks for your advice.

UltraGridExcelExporterTestSolution.zip
Parents
  • 469350
    Verified Answer
    Offline posted

    Hi,

    When exporting asynchronously, the export is done using slices of time. That means that the component does a little bit of exporting, then releases processing back to the application for a time, then does a little but more of the export, etc.

    That's the nature of asynchronous exporting. So exporting asynchronously will always take longer than synchronous exporting. That's just the laws of physics. The time has to come from somewhere. :)

    The trade off is, of course, that during the asynchronous export operation, the UI of the entire application doesn't lock up - so the user can still do other things.

    You might be able to speed up the asynchronous export by giving more time to the export process and less free time to the application. You can adjust the time slices using a couple of static properties:

    Infragistics.Win.UltraWinGrid.AsynchronousExportManager.AsynchronousExportDuration
    Infragistics.Win.UltraWinGrid.AsynchronousExportManager.AsynchronousExportInterval

    By increasing the duration or deceasing the interval you will give more time to the export and less time to the application. The risk there is that the UI for the rest of the application might not be as responsive while the export is in progress - and this may vary based on the speed of the machine, so just because it's fine on your machine doesn't necessarily mean it will be fine on a user's machine if their machine is slower than yours.

Reply Children