Getting crosstab.bucket.measure.limit Error When Runnig a Cross Tab Report In TIBCO JasperReports® Server

Question/Problem:

User has created a cross tab report and tested it in TIBCO Jaspersoft® Studio. But when running the report on the server, user got the following error:

net.sf.jasperreports.crosstabs.fill.calculation.BucketingService.crosstab.bucket.measure.limit

User wants to know what this error means and "how to fix it so that we can run the cross tab report on the server".


Answer/Suggested Resolutions:

The crosstab calculation engine performs all calculations in memory. In case large volumes of data are processed, it could be possible to run out of memory due to the large number of totals and aggregation variables that the engine keeps track of.

To avoid the situation in which the JVM raises an OutOfMemory error, and thus triggers memory reclaim procedures with potentially serious effects on the application’s overall behavior, a crosstab governor has been put in place. This is basically a simple memory consumption test that the engine performs when filling a crosstab, to check whether a given memory threshold has been reached. When the limit is reached, the program raises an exception that can be caught and dealt within the caller program, preventing a more serious OutOfMemory error from occurring.

The governor threshold is given as an integer number representing the maximum number of cells multiplied by the number of measures in the generated crosstab. It can be set using the net.sf.jasperreports.crosstab.bucket.measure.limit configuration property. This property defaults to -1, meaning that the crosstab governor is disabled by default. In JasperReports® Server deployment, this limit is configured in jasperreports.properties file under deployed jasperserver-pro\WEB-INF\classes\ directory. The default size is 100,000.

net.sf.jasperreports.crosstab.bucket.measure.limit=100000

User can increase the limit in the above jasperreports.properties file property setting to avoid the error. However, we caution users to consider performance impact on the server when increasing the limit, instead redesign report and reduce the amount of buckets being generated whenever possible to work around the issue.


TTC-20181009

Feedback
randomness