Use the close method to free up the report

Reports are stored on the Report Application Server, but they are represented on the Web server by an instance of ReportClientDocument. If the ReportClientDocument instance passes out of scope without calling the ReportClientDocument.close method, the Report Application Server keeps the report open in memory, even though the report can no longer be accessed. When those circumstances are repeated in a highly scaled situation, the memory on the Report Application Server fills with reports that are no longer being accessed on the Web server.
To resolve that problem, call the ReportClientDocument.close method. The report is closed on the Report Application Server and the memory is released for further reports.
When to call the ReportClientDocument.close method
The close method should not be called on the page before the report has been displayed, because the report must remain open on the server until the display process has been completed.
For a ReportClientDocument instance, the close method immediately closes the report and the report cannot be reopened. Therefore, if the close method is called before the report is displayed, the report will be inaccessible and an exception will be thrown.