Tuesday, August 10, 2010

how to prevent lack of memory while executing large jasper reports

        JRSwapFile swapFile =
                    new JRSwapFile(getServletContext().getRealPath("/report/swap/"), 1024 * 50/* 50 KB */, 2);
        virtualizer = new JRSwapFileVirtualizer(40, swapFile);
        virtualizer.setReadOnly(false);
        reportParam_.put(JRParameter.REPORT_VIRTUALIZER, virtualizer);

No comments:

Post a Comment