Rank: Advanced Member Groups: Member
Joined: 11/8/2015 Posts: 42
|
I am trying to convert a html string to pdf and I keep getting the operation has timed out at EO.Pdf.HtmlToPdf.ConvertHtml(htmlString, stream).
Stack Trace = [ at EO.Internal.aiq.a(ak8 A_0) at EO.Pdf.HtmlToPdf.ConvertHtml(String html, PdfDocument doc, HtmlToPdfOptions options) at EO.Pdf.HtmlToPdf.ConvertHtml(String html, Stream stream, HtmlToPdfOptions options)
Here is just a subset of my code: EO.Pdf.HtmlToPdf.Options.MaxLoadWaitTime = 3000000; var stream = new MemoryStream(); EO.Pdf.HtmlToPdf.ConvertHtml(htmlString, stream);
In this particular case, my htmlString is 458MB in size. When the program hits the ConvertHtml line, within 10 seconds, it throws the timeout error.
I am running EO.PDF version 15.3.43.0
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,229
|
Hi,
You definitely want to cut down your HTML string size. This looks much more like an out of memory error other than a time out error. The converter worker process has a total memory space of 2GB, so it is absolutely not possible for it to load, parse and render a 458MB string --- not even close. You should cut your HTML down to the scale of 10MB and then try again. Anything significantly above it is pushing the limits --- depending on the complexity of the HTML, sometimes even 10MB HTML can cause out of memory error.
Thanks!
|