public void runReport(Map<String, Object> params, FillListener fillListener) { try { Map<String, Object> reportParams = reportParams(params); AsynchronousFillHandle asyncHandle = AsynchronousFillHandle.createHandle( jasperReportsContext, report, reportParams); if (fillListener != null) { asyncHandle.addFillListener(fillListener); } AsyncJasperPrintAccessor accessor = new AsyncJasperPrintAccessor(asyncHandle); asyncHandle.startFill(); JasperPrint print = accessor.getFinalJasperPrint(); reportComplete(reportParams, print); } catch (JRException | NoSuchAlgorithmException | IOException e) { throw new RuntimeException(e); } }