We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose PDF for Java 17.8 ignores license

we have a license for Aspose.Total, but only Aspose.Pdf library seems to be doing this i.e. it adds evaluation watermark to the documents.
Our license should expire on: 20180516
When I tried to use v17.7 it was working ok.

One other question:
is this PDFJAVA-36807 Epub to PDF: java.awt.HeadlessException Bug
the same thing as is mentioned here: java.awt.HeadlessException thrown when converting HTML to PDF PDFJAVA-36737 ?
Until that bug [already half year old] is fixed we cannot update the library, which is really bad.



Thanks for contacting support.

Please make sure that you are applying license settings properly and if so, please share your license file with us, so that we can test the scenario in our environment and address it accordingly. Please note that, I have marked this post as private, so that any file, shared within this forum thread, will only be accessible to Aspose Staff.

We are glad to inform you that mentioned issue(s) have been resolved and their fix has been provided with Aspose.Pdf for Java 17.8. Please download latest version of the API form shared link and in case if you face any other issue, please feel free to contact us.

Here is the license file:
Aspose.Total.Java.zip (706 Bytes)


Thanks for sharing license file.

We have tested the scenario by setting your license file for Aspose.Pdf for Java 17.8 and were unable to notice any evaluation mark in resultant document. Please check following code snippet which we have used to test the scenario. For your reference, we have also attached resultant PDF file.

com.aspose.pdf.License lic = new com.aspose.pdf.License();
Document doc = new Document();
Page page = doc.getPages().add();
TextFragment tf = new TextFragment("Hello World!");
doc.save(dataDir + "LicTest.pdf");

LicTest.pdf (1.9 KB)

Please make sure that you are setting license correctly for Aspose.Pdf for Java as well, because in order to use complete feature of each API, you need set license for it separately. In case if you still face any issue, please share a sample code snippet and further details regarding your Application, so that we can test the scenario in our environment and address it accordingly.

so I finally found the cause of the problem. The scenario is like this:

  1. on main thread set license
  2. on another thread do manipulations with documents
    In v17.8 this results in license to be ignored -> either throws exception or evaluation watermark is added
    This was working in previous versions i.e. v17.7 and earlier

See attached project:
pdflicenseissue.zip (841.9 KB)
change aspose-pdf in pom.xml to 17.8 and the app will throw an exception


Thanks for sharing sample project.

We have tested the scenario in our environment and managed to replicate the issue, which you have mentioned. It seems that second thread (related to document manipulations) executes before the first thread sets the license for the API. However it runs fine with earlier version of the API, which we have tested in our environment as well.

For now, as a workaround, you may set license within the same thread, where document is being manipulated, as for the sake of correction, we have logged an investigation ticket as PDFJAVA-37084 in our issue tracking system. We will further investigate the reasons behind this behavior and keep you updated with the status of its resolution. Please be patient and spare us little time.

We are sorry for the inconvenience.


Thanks for your patience.

We are pleased to share that the issue PDFJAVA-37084 reported earlier is resolved in latest release of Aspose.Pdf for Java 17.9.

Please try using the latest release version and in case you face any issue, please feel free to contact.