I have to generate configurable reports in pdf format with java. I have velocity template which has the CSS formatting of report and place holders for actual data.
Velocity is processing the data very efficiently even when data set multiple thousands of records.
I then convert this processed html string into pdf using openhtmltopdf.pdfbox PdfRendererBuilder. Unfortunately this operation takes around 4 minutes on 10 000 records. I want to reduce this time.
How can this pdf generation time be reduced? keeping in mind:
- I only have open source libraries in my repo that I can use and do not have many options. I have tried with itext5.5, pdfbox2.0.4, openhtmltopdf. I dont have maven repository access on my development environment.
- I dont want to rewrite java code for any new upcoming report, I want to write one configurable template, just call that template with data set to generate pdf report.
- Data volume is huge, so I am looking for optimized solutions.
- This should support right to left language as well.