Set up a cache filter for Tomcat or JBoss
You can set up a cache filter so that static files (image files, CSS files, and JavaScript files) don't expire. When the expires header is set to sometime in the future, the browser will immediately get those static files from its cache, if they exist, and only make the server request if it doesn't have them. If the expires header is not set to the future the the browser sends a conditional request to the server asking if the file has changed, then the server returns an HTTP 304 response if the file has not changed. Many JasperReport pages have 100 or more static files, so elliminating these round trips can significantly lighten the server load. Typically we see around 10% improvement in performance and in some cases as much as 50% improvement.
See Also:
- Setting up a cache filter in Tomcat 6 or JBoss for static files
- Enabling the cache filter in Tomcat 7
Other Performance Tips:
Measure and Test
Ad Hoc
- Set query limits on the "Ad Hoc Options" page
- Modify the Ad Hoc caching values if your data does not update constantly
Tomcat
- Compress HTTP responses at the Tomcat level
- Increase the maximum thread count at the Tomcat level
- Disable automatic deployment on production servers using Tomcat
Database
- Index columns in the database to speed up domain-based reports
- Set the fetch size in the jasperreports.properties file to modify the number of rows to fetch
JasperReports Configuration Items
- Modify Virtualizer Settings for Very Large Reports
- Modify the jasperreports.properties file to disable multi-line data processing
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now