Getting an error reading an html file into a Document object using PDF for Java

The exception seems thrown when the following code is called:

com.aspose.pdf.Document document = new com.aspose.pdf.Document(htmlPageFileName, htmloptions);

Exception in thread “java.lang.ThreadGroup[name=main,maxpri=10]_4” java.lang.OutOfMemoryError: unable to create new native thread
at java.lang.Thread.start0(Native Method)
at java.lang.Thread.start(Thread.java:717)
at java.util.concurrent.ThreadPoolExecutor.addWorker(ThreadPoolExecutor.java:957)
at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:1367)
at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:112)
at com.aspose.pdf.internal.l57k.l2u.lI(Unknown Source)
at com.aspose.pdf.internal.l57k.l2u.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lu.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lf(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lj(Unknown Source)
at com.aspose.pdf.internal.html.HTMLImageElement$2.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lt.lk(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lu(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lI(Unknown Source)
at com.aspose.pdf.internal.l38v.ly$2.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lt$1.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lt.lk(Unknown Source)
at com.aspose.pdf.internal.l33t.lu.lf(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lI(Unknown Source)
at com.aspose.pdf.internal.l38v.ly.lI(Unknown Source)
at com.aspose.pdf.internal.html.dom.Document$lf$1$1.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lt.lk(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.ld(Unknown Source)
at com.aspose.pdf.internal.l33t.lb.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lb$1.lI(Unknown Source)
at com.aspose.pdf.internal.l33t.lf$lI$1.lI(Unknown Source)
at com.aspose.pdf.internal.l57k.l1j.lI(Unknown Source)
at com.aspose.pdf.internal.l57k.l1n.run(Unknown Source)
at java.lang.Thread.run(Thread.java:748)

The html file contains such image tags.
SyntaxEditor Code Snippet

@wshen,

Can you please attach the source HTML in a zip file, please?

items2.zip (204.6 KB)

@wshen,

I was getting some strange behavior with this Html document so I did several tests, including doing the conversion using the C# version of Aspose.Pdf, which worked out but took an unusual amount of time.

Then in Java did not work. So I will be creating a ticket for the Dev team now…

@wshen
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): PDFJAVA-42544

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

Any update on the status of this ticket? Or we will need to obtain paid support service first? Just want to see if any forthcoming release may address this issue.

@wshen,

Hi! The ticket has not been fixed yet, since the Free Support Queue is first come, first served.

Paid support has several perks besides the ticket getting priority on the queue. You will have access to the Paid support team, which has access to the dev team and can give you much more in-depth answers.

Any status update on this ticket?

@wshen

We are afraid that the earlier logged ticket has not yet been resolved due to other pending issues in the queue. Nevertheless, we have recorded your concerns and will surely update you as soon as we make some progress towards ticket resolution. Please be patient and spare us some time.

We are sorry for the inconvenience.