Hello,
We are trying to move to Java 11 and we have found that Aspose PDF Java (latest version and previous versions) is getting stuck. Its fine with Java 9. This is happening on AWS linux, Windows and Mac OS.
The following stack trace:
Blockquote
java.lang.Thread.State: WAITING
at java.lang.Object.wait(Native Method)
- waiting on java.lang.Object@46ccb9dc
at java.lang.Object.wait(Object.java:328)
at com.aspose.pdf.internal.l57n.l3k.lI()
at com.aspose.pdf.internal.l57n.l3k.dc_()
at com.aspose.pdf.internal.l33l.lh.lI()
at com.aspose.pdf.internal.l33l.lk.dispose()
at com.aspose.pdf.internal.html.dom.Document.navigate()
at com.aspose.pdf.internal.html.dom.Document.()
at com.aspose.pdf.internal.html.HTMLDocument.()
at com.aspose.pdf.internal.html.HTMLDocument.()
at com.aspose.pdf.l6h.lI()
at com.aspose.pdf.l6h.lI()
at com.aspose.pdf.ADocument.lI()
at com.aspose.pdf.ADocument.()
at com.aspose.pdf.Document.()
We are using the following code:
Blockquote
InputStream targetStream = new ByteArrayInputStream(html.getBytes(“UTF-8”));
HtmlLoadOptions htmloptions = new HtmlLoadOptions();
htmloptions.setInputEncoding(“UTF-8”);
Font font = FontRepository.findFont(“Arial”);
font.setEmbedded(true);
htmloptions.getPageInfo().getDefaultTextState().setFont(font);
com.aspose.pdf.Document doc = new com.aspose.pdf.Document(targetStream, htmloptions);
The following html is being used as input and can be downloaded from here: https://customerservices.glasscubes.com/share/s/83goi9kln635uvugkr73d5ank