The scheduled reporting feature of JasperReports Server allows reports to be run at pre-configured time intervals. Optionally, notification email can be sent to users to let them know that new reports are available.
Additional Fix for Scheduled Report with JNDI Data Source
Under the WebSphere application server, if you have a scheduled report that uses a JNDI data source you will need to make an additional configuration in order for the JNDI lookup to be resolved correctly.
There are special WebSphere specific configuration files included in the jasperserver-pro.war archive. These files are generated during the installation process. In order to enable this fix, you will need to rename the WebSphere specific files to remove the prefix webSphere. Two of the file rename operations will overwrite the existing configuration file names.
Rename: | WEB-INF/webSphere-applicationContext-report-scheduling-wm.xml |
To: | WEB-INF/applicationContext-report-scheduling-wm.xml |
Rename: | WEB-INF/webSphere-js.quartz.base.properties |
To: | WEB-INF/js.quartz.base.properties (overwrite existing file) |
Rename: | WEB-INF/webSphere-js.scheduling.properties |
To: | WEB-INF/js.scheduling.properties (overwrite existing file) |
Notes on this configuration change:
Since JasperServer 3.7 and 4.0, a new work manager class is used to run scheduled report jobs under WebSphere. The JNDI name of the work manager is configured in the WebSphere version of js.scheduling.properties. Also, for WebSphere, we need a different default value for the specified JNDI name (wm/default). This is also defined in the WebSphere version of js.scheduling.properties.
The number of threads that run report jobs is no longer configured in js.quartz.base.properties, but is instead provided by the work manager configuration.
Additional Change for Mail Server Authentication
If your mail server requires authentication, edit the applicationContext-report-scheduling.xml file after applying the changes above.
1. | Extract the file from the WAR archive: |
"%JAVA_HOME%binjar" xf jasperserver-pro.war WEB-INF/applicationContext-report-scheduling.xml
2. | Open the file for editing and locate the reportSchedulerMailSender bean. |
3. | Set the javaMailProperties key="mail.smtp.auth" value to true. |
4. | Save the file and replace it in the archive: |
"%JAVA_HOME%binjar" uf jasperserver-pro.war WEB-INF/applicationContext-report-scheduling.xml
5. | Delete the WEB-INF directory that was created, along with the file it contains. |
For more information about setting up report scheduling, refer to Configuring Report Scheduling.
Recommended Comments
There are no comments to display.