Reports very slow
Reports very slow
Sometimes viewing reports get in a state where it's very very very slow...Loading a report that's only 5 pages can take 30 seconds....And paging from one page to the next takes 5-10 seconds.
The rest of our application is running just fine...no degradation in performance what-so-ever...Just reports.
One solution is to do a IISRESET...Once we do this...the same report with the same data as above...takes less then 2 seconds to load...and paging from one page to the next takes 1 second.
Any idea's what could be wrong??? or how to solve this problem.
We've tried everything to reproduce the problem....Nothing stands out HOW we get in this state...All of a sudden reports start running slow...Monitoring the system doesn't show anything...We also tried clearing the data-cache...and that had no effect either. Retrieving the data and creating a dataset that is used by the report is as fast as always (1 second or less). The slowness is in the stiReport.Render(true).
This can happen on ALL our reports...
Reports very slow
We've had several people looking at this and we can reproduce it.
Here is a way to reproduce the report slowness.
1) Create a new report. This isn't an issue if the reports are less then 500 records...So create a report that has 500 records or more.
2) Save the report and exit out the report creator.
3) Now run the report. At this point it's very very slow. Takes about 20-30 seconds to load the report...and 5-10 seconds to go from page to page.
I also was running in debug...and noticed that when loading the report...it's Loading Symbols of mxdwdui.dll OVER AND OVER AGAIN...maybe 20-30 times.
4) Run any other report...same thing...very very slow.....
5) Reset the app pool. Easiest way to do this was to just edit the web.config file.
6). Run the same report again with the same data...and now it loads in about 5 seconds...and going from page to page takes about 1-2 seconds (very acceptable).
We can run any report we want with very acceptable response times...But once a report is created and saved...running reports is very very slow.
Reports very slow
Well we think we found it.
I have a method called load report...
private void LoadReport(Stimulsoft.Report.StiReport report)
{
WebReportDesigner.UseCache = false;
Stimulsoft.Report.Web.StiWebDesignerOptions.ModifyDictionary = true;
Stimulsoft.Report.Web.StiWebDesignerOptions.ModifyConnections = true;
Stimulsoft.Report.Web.StiWebDesignerOptions.ModifyVariables = true;
//ReportHelper.Instance.SetDefaultPageSize();
//report.Dictionary.Synchronize();
WebReportDesigner.Design(report);
}
The problem was the commented out line of code ...... report.Dictionary.Synchronize();
Real weird why that caused the problems we were having. By commenting out that line of code no more report slowness.
Question....What is Dictionary.Synchronize used for...and when should it be used.
Reports very slow
Hello,
Strange problem.
The Synchronize method synchronizes the data dictionary in a report and data from the database which were registered in a report using the RegData method.
You need to call the method only if data were changed (new columns were added or data sources).
If there are no changes then there is no need to call the method.
If a report requests all data itself (for example, via sqlconnection) then there is no need to call the method.
Thank you.
Strange problem.
The Synchronize method synchronizes the data dictionary in a report and data from the database which were registered in a report using the RegData method.
You need to call the method only if data were changed (new columns were added or data sources).
If there are no changes then there is no need to call the method.
If a report requests all data itself (for example, via sqlconnection) then there is no need to call the method.
Thank you.