Hello Support Team - Thanks in Advance for your great support at this forum.
We have Aspose.PDF license. Tried with both Aspose.PDFand Aspose.PDF.Drawing latest version.
At our .Net Core with AWS Lambda.
Recently at one of our upstream lambda upgraded into latest version 23.12.0 (Aspose.PDF.Drawing)
This lambda converts html files into pdf.
At downstream lambda that combines multiple pdf files into one pdf. It was working fine before the upstream lambda upgradation.
Throwing the error at this line pdfEditor.Concatenate
Error : Stream was not readable.
at Aspose.Pdf.Facades.PdfFileEditor.#=zuDPoNcE=(Stream[] #=zfj9mPPQ=)
at Aspose.Pdf.Facades.PdfFileEditor.Concatenate(Stream[] inputStream, Stream outputStream)
Code Portion:
using (MemoryStream finalPdfStream = new MemoryStream())
{
if (pdfStreams != null && pdfStreams?.Count() > 0)
{
LoggerService.Log($“Lambda Max time exceeding : All pdf files combined in this run is: [{filesCombined}]”);
bool success = pdfEditor.Concatenate(pdfStreams, finalPdfStream);
byte[] combinedPdfContent = finalPdfStream.ToArray();
finalPdfFile = combinedPdfContent;
pdfStreams = null;
}
}
await _combineFileService.SavePDFFile(finalPdfFile, tempFinalPDFFolder);