|
did you close the PDF file upon creation completion? it should be ok using another API to convert it(it just need readonly operation,am I right?)
I use itext to generate PDF file in memory, and PDF-renderer to convert PDF to image, you can take a look at http://www.touchpdf.com.
for example, I needed to concatenate serveral PDF files from DB:
ByteArrayOutputStream baos = new ByteArrayOutputStream();
PdfCopyFields copy = new PdfCopyFields(baos);
..................................
copy.addDocument(.....);
copy.close();
byte[] finalPdf = baos.toByteArray();
then you can persist finalPdf to DB or serve it to browser directly....
|