HakanL / WkHtmlToPdf-DotNet

C# .NET Core wrapper for wkhtmltopdf library that uses Webkit engine to convert HTML pages to PDF.
GNU Lesser General Public License v3.0
366 stars 66 forks source link

Add ability to process pdf generation on multiple threads #98

Closed t00 closed 1 year ago

t00 commented 1 year ago

Current SynchronizedConverter implementation seems to not allow specifying number of threads used when generating pdfs. Allowing multiple instances of whhtmltopdf and using them in parallel would make the library several times more performant if needed.

HakanL commented 1 year ago

It's my understanding that the native library doesn't support multi-threading, and it's loaded in the main AppDomain, so I don't think it will be as easy as just setting up a number of threads. But if you can figure out how to load multiple copies of the native library then it may work.