Intermittent Issue while modifying word properties at the step of loading license file

we are using aspose word library (aspose-words-25.6-jdk17.jar) in our java code for modifying word properties and getting below intermittent issue at the step of loading license file. document gets reprocessed upon retry but we need to find out the root cause of this.

java component is hosted on WebSphere Application Server (9.0.5.21) and deployed over FileNet platform using IBM Java SDK (8.0.8.30 - Java 8). we placed the license file and java file within the java adaptor. WebSphere is configured to load parent class first.

[9/10/25 22:57:56:904 GST] 000000b9 SystemErr     R AWT blocker activation interrupted:
[9/10/25 22:57:56:904 GST] 000000b9 SystemErr     R java.lang.InterruptedException
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.lang.Object.waitImpl(Native Method)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.lang.Object.wait(Object.java:248)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.lang.Object.wait(Object.java:187)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at sun.awt.AWTAutoShutdown.activateBlockerThread(AWTAutoShutdown.java:362)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at sun.awt.AWTAutoShutdown.setToolkitBusy(AWTAutoShutdown.java:274)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at sun.awt.AWTAutoShutdown.notifyToolkitThreadBusy(AWTAutoShutdown.java:157)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at sun.awt.windows.WToolkit.<init>(WToolkit.java:269)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.lang.J9VMInternals.newInstanceImpl(Native Method)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.lang.Class.newInstance(Class.java:2130)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.awt.Toolkit$2.run(Toolkit.java:884)
[9/10/25 22:57:56:906 GST] 000000b9 SystemErr     R 	at java.awt.Toolkit$2.run(Toolkit.java:866)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at java.security.AccessController.doPrivileged(AccessController.java:690)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:865)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at java.awt.SystemColor.updateSystemColors(SystemColor.java:484)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at java.awt.SystemColor.<clinit>(SystemColor.java:476)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.internal.zzWji.zzYcF(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.internal.zzZu1.zzYcF(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzlL.zzi4(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzXYH.zzi4(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzVOD.zzi4(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzKD.zzWod(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.zz4O.zzXtx(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzZIb.visitFieldStart(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.FieldStart.accept(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptChildren(Unknown Source)
[9/10/25 22:57:56:907 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptCore(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.Paragraph.accept(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptChildren(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptCore(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.Body.accept(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptChildren(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptCore(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.Section.accept(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptChildren(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptCore(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.Document.accept(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.zz4O.zzi4(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzXlK.zzWXW(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzXlK.visitDocumentEnd(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.Document.acceptEnd(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.CompositeNode.acceptCore(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.Document.accept(Unknown Source)
[9/10/25 22:57:56:908 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzXlK.zzYqr(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzOe.zzX8f(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.Document.updatePageLayout(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzZ32.zzWpG(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzXuz.zzYIH(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzlz.zz9r(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzlz.zzWod(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzlz.zzi4(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.zzlz.zzXb4(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.Range.updateFields(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.aspose.words.Document.updateFields(Unknown Source)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at com.gbm.sws.filenet.pe.util.FileUtil.modifyUsingAspose(FileUtil.java:275)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at **com.gbm.sws.filenet.pe.SWSOperations.modifyMSWordProperties**(SWSOperations.java:594)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:90)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at java.lang.reflect.Method.invoke(Method.java:508)
[9/10/25 22:57:56:909 GST] 000000b9 SystemErr     R 	at filenet.vw.integrator.adaptors.pejava.PEJavaAdaptor.execute(PEJavaAdaptor.java:102)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMExecuteAStepTask$TaskWorker$1.run(CMExecuteAStepTask.java:163)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMExecuteAStepTask$TaskWorker$1.run(CMExecuteAStepTask.java:147)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at java.security.AccessController.doPrivileged(AccessController.java:782)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at javax.security.auth.Subject.doAs(Subject.java:570)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at com.ibm.websphere.security.auth.WSSubject.doAs(WSSubject.java:196)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at com.ibm.websphere.security.auth.WSSubject.doAs(WSSubject.java:153)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at sun.reflect.GeneratedMethodAccessor18.invoke(Unknown Source)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at java.lang.reflect.Method.invoke(Method.java:508)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at com.filenet.apiimpl.util.J2EEUtilWSBase.doAs(J2EEUtilWSBase.java:82)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at com.filenet.api.authentication.SubjectCredentials.doAs(SubjectCredentials.java:82)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at com.filenet.api.util.UserContext.doAs(UserContext.java:159)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMExecuteAStepTask$TaskWorker.call(CMExecuteAStepTask.java:146)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMExecuteAStepTask$TaskWorker.run(CMExecuteAStepTask.java:191)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMExecuteAStepTask.doMyJob(CMExecuteAStepTask.java:320)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMDispatcherTask.process(CMDispatcherTask.java:417)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMDispatcherTask.doMyJob(CMDispatcherTask.java:172)
[9/10/25 22:57:56:910 GST] 000000b9 SystemErr     R 	at filenet.jpe.cm.CMBaseTask.doJob(CMBaseTask.java:111)
[9/10/25 22:57:56:911 GST] 000000b9 SystemErr     R 	at filenet.jpe.server.common.DelayBackgroundTask.run(DelayBackgroundTask.java:232)
[9/10/25 22:57:56:911 GST] 000000b9 SystemErr     R 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1160)
[9/10/25 22:57:56:911 GST] 000000b9 SystemErr     R 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
[9/10/25 22:57:56:911 GST] 000000b9 SystemErr     R 	at java.lang.Thread.run(Thread.java:825)

@zeeshan1989

The intermittent issue you’re experiencing while loading the license file in the Aspose.Words library may be related to the AWT (Abstract Window Toolkit) blocking mechanism, as indicated by the InterruptedException in your logs. This can occur in environments where AWT is not properly initialized or when there are threading issues.

Here are several suggestions to troubleshoot and potentially resolve the issue:

  1. Check License File Path: Ensure that the license file is correctly placed and accessible. Using an absolute path can help avoid any path resolution issues.

  2. AWT Initialization: Since your application is running on WebSphere, verify that AWT is properly initialized. Consider testing your application in a different environment or configuration to determine if the issue persists.

  3. Thread Management: Review your thread management practices. If your application is heavily multi-threaded, ensure that the license loading is performed in a thread-safe manner.

  4. WebSphere Configuration: Given that WebSphere is configured to load the parent class first, check for any conflicting versions of the Aspose library in your classpath.

  5. Error Handling: Implement comprehensive error handling around the license loading code to catch and log any exceptions that may provide further insight into the issue.

  6. Update Aspose Library: If feasible, consider updating to a newer version of the Aspose.Words library, as there may have been bug fixes or improvements related to licensing.

If the problem persists, consider reaching out to Aspose support with detailed logs and your environment setup for further assistance.

@zeeshan1989 According to stack trace the problem occurs upon updating fields in the document. Could you please attach the problematic input document and code that will allow us to reproduce the problem? We will check the issue on our side and provide you more information.