Optimzeresource is increasing size drastically

@asad.ali Thanks your reply helped me. I Updated my Aspose.PDF from 22.1.0 to 23.11.0 and it resolved my Issue . But now i am facing new issue with another PDF Documents as below
image.png (116.4 KB)

1.0Copyright (c) 2001-2023 Aspose Pty Ltd. All Rights Reserved.11/30/2023 11:28:59 AMDocument information entry ‘CreationDate’ not synchronized with metadata property ‘xmp:CreateDate’Document information entry ‘ModDate’ not synchronized with metadata property ‘xmp:ModifyDate’Required property ‘pdfaid:part’ for schema ‘pdfaid’ missingRequired property ‘pdfaid:conformance’ for schema ‘pdfaid’ missingObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual positionObject offset in the document stream is mismatched with its actual position

@GayatriNaik

You are facing issue using the same code snippet? Is it an exception message? Can you share the sample document with us please?

Hi @asad.ali yes code is same but the package version for aspose.pdf I have increased from 22.1.0 to 23.11.0 .

Sorry but asper policy we are strictly strictly not allowed to share project specific documents.

Atleast tell me what this error is related to?
Where meta data is looking for ModDate CreateDate which I can see in the error text under Metadata element of error log.

@GayatriB

It looks like an XML log that API generates while converting a PDF into PDF/A. It is unclear how you are receiving it in console. Can you please share if there is any exception thrown? We are afraid we cannot continue with this information any further. We need some more insights as well as a sample file (as requested earlier).

@asad.ali I have already set below 2 Info in metadata. Is it that Aspose.PDF.Document is refering different Metadata i mean instad of Info.ModDate its expecting Info.ModifyDate ?? Shall i add it explicitly ? I cannot see that Property in DocumentInfo so i cannot set document.Info.ModifyDate ame is for CreationDate.

Please suggest. Also not sure then why i am getting this XML Error (Its not logged in Console Its there in Document Metadata itself ) for another Document for which i raised this issue. Its Gettting raised only for few other Documents since the code is same for all the documents
??

image.png (13.2 KB)

@GayatriNaik

This error can have something to do with document XML structure. We are afraid we cannot comment much without doing technical analysis with the sample PDF. As shared earlier, you can share your documents securely with us here. You can prepare some sample PDF as well that can be easily shared with us and can be used to replicate the issue.

Thanks for your Reply @asad.ali But your reply is not satisfatory.

Aspose should be able to tell us clearly what this error is related to , Why it comes and how we can resolve it . Just Sharing Doc cant solve issue all the time Right ??

atleast if we know that it is related to Which Metadata, from where it is Picking up . with what it is cross verifying, then we can resolve it at our end too.

@GayatriNaik

We have responded to your similar inquiry in the other thread. You can please follow up there.