Performance Issue with Document Conversion Using Aspose PDF

Hi Aspose Support Team,

I am writing to seek your assistance regarding a performance issue we are experiencing with the document conversion process using Aspose PDF. we use Aspose.Total.NET license in our production servicer

Environment Details:

  • Our servers are hosted in AWS using ECS Fargate.
  • Each task is provisioned with 4 vCPUs and 20 GB of memory.
  • We deploy only one container running our application service code per task.
  • we scale the task value based on the cpu utilization alarms

Issues Encountered:
We have observed that the document conversion process is slower than expected and takes more cpu utilization resulting in constant scale up activity and cost. Specifically, converting a 20 MB document takes longer than anticipated. Each 20 MB Document consumes >1000 cpu units (AWS CPU utilization metric)

Questions and Requests:

  1. Service Size Capacity Recommendations:
    • Could you provide recommendations on the optimal service size capacity (vCPU and memory) for faster processing of documents?
  • Any recommendation on type of infrastructure to use ?
  1. Idle Time for 20 MB Documents:

    • What is the expected idle time for converting a 20 MB document under ideal conditions?
    • Attached the code for reference
  2. Threading and Parallel Processing:

    • How many documents can be processed concurrently without significant degradation in performance aka how to alter the code for aspose to perform multithreading ?

Thank you for your assistance.

S Rajan

CPU utilization from container.png (7.0 KB)

test document - Upload Files | Free File Upload and Transfer Up To 10 GB

@sarath6.rajan

This, if we do not take into account the system performance, depends on the document itself and its size is not an exhaustive characteristic of the time required for its conversion. Therefore, it is difficult to give any estimate of time based on the document size.

Processing can be carried out in multi-threaded mode, provided that each thread processes a separate document. The correctness of multi-threaded processing of one document is not guaranteed. As for the previous question - this should be determined by trying in a specific environment and on specific documents. It is not possible to say that for such and such CPU, memory and documents of such and such size, exactly so many threads should be used and this will be optimal.

Thanks for the prompt and fast response, @sergei.shibanov .

But I like to poke more on this topic and looking for additional help.
Is it possible to share with us the best performance metrics guaranteed that came out of the aspose.pdf testing from product team? (like file size, time taken, service configs used on test system)

we can use to calculate the server needs and scale up activities based our application traffic.

Also any comments on code shared with the test file ?

Thanks in advance

@sarath6.rajan
The development team has tests to verify that performance has not dropped compared to the previous version, but I cannot provide the documents used, and any characteristics without them are meaningless (besides, this is not public information). I repeat, the processing time depends on the content and structure of the document and can differ significantly for documents of the same size.