Exploding file size and runtime when converting PDF with Watermark to PDF/A

When converting attached watermarked file from non PDF/A to PDF/A with code like this

try (InputStream inputStream = this.getClass().getResourceAsStream("/test.pdf");
             ByteArrayOutputStream bos = new ByteArrayOutputStream();
             FileOutputStream fos = new FileOutputStream("explodedPdf.pdf")) {
            Document doc = new Document(inputStream);
            doc.convert(bos, PDF_A_1A, ConvertErrorAction.Delete);
            doc.save(fos, new PdfSaveOptions());
            System.out.println(bos);
        }

the file size of around 300KB of the original file grows to over 110 MB and takes very long (55sec on a test system) to convert.

We are using aspose for java version 23.9

test.pdf (331,8 KB)

@mprischink

We tested using 24.1 version and output PDF size was around 11MB. Can you please try with the latest version and share the file with us that you obtained at your side?

Thanks for the quick reply.

I just tested with 24.1 and can confirm, that the resulting file is around 11MB. Unfortunately that is still a lot bigger than expected.

Further testing showed, that direct PDF/A compliant conversion of the source word document from within ms word or with aspose word to pdf transformation results in a much smaller resulting pdf file.

I attached the original word document.

test-word-watermark.docx (19,9 KB)

the 11MB conversion with aspose 24.1

explodedPdf.7z (2,3 MB)

@mprischink

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): PDFJAVA-43581

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

Is there any update available regarding this issue?

From 20KB to 11MB is still a lot bigger than expected and warranted from our point of view.

@mprischink

We are afraid that the earlier logged ticket has not been yet resolved due to other pending issues in the queue. We will let you know as soon as we make some progress towards it resolution. Please be patient and spare us some time.

We are sorry for the inconvenience.