We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

.docx to .pdf performance on AWS Lambda (.NET)

Hi everyone,

We’re implementing our custom .docx to .pdf converter using AWS lambda in .NET using Aspose.Words (21.5.0). We’re storing custom fonts on S3 Bucket (~500 MB). Each time the lambda context is disposed of, it takes ~40 seconds to recreate it.

Is there any way to store the font search info cache into an external file and read this information from there instead of S3?

Related article: How to use Noto fonts in AWS Lambda using Java

Thanks in advance!

@vadym.shashkov Currently there is no way to cache the FontSearchInfos into a file. I logged this feature request as WORDSNET-22278 in our defect tracking system. We will let you know once this feature is available.

Thank you for such a quick response!

Maybe there is a way on how we can serialize this object and save it to file manually? Because the search values in our case will always be the same.

@vadym.shashkov Unfortunately, currently I cannot suggest you a way to cache FontSearchInfos. Probably to speedup the the initialization process you can first check what fonts are used in the document and read only these fonts into the font sources.

But you should note that FontInfos are loaded from document’s font table, which might be incomplete or even missing.

The issues you have found earlier (filed as WORDSNET-22278) have been fixed in this Aspose.Words for .NET 21.12 update also available on NuGet.

@vadym.shashkov Please see Aspose.Words 21.12 release notes to learn more about font search info caching feature.

Thank you!

We will take a look and write back once we test it :slight_smile: