Bug in 6.8.8 starting desktop app via webstart

A ‘desktop’ app fails to start in 6.8.8.

I am using Java 1.8+ to run the app. If I run it using the ‘start scripts’ from a terminal it runs fine, but from webstart, I get the following in the logs (the only error):

  <message>20:01:43.242 ERROR com.haulmont.cuba.desktop.App - Error initializing application
java.lang.ExceptionInInitializerError: null
	at org.eclipse.persistence.internal.helper.ClassConstants.&lt;clinit&gt;(ClassConstants.java:64)
	at org.eclipse.persistence.expressions.ExpressionOperator.&lt;init&gt;(ExpressionOperator.java:255)
	at org.eclipse.persistence.expressions.ExpressionOperator.notOperator(ExpressionOperator.java:2123)
	at org.eclipse.persistence.expressions.ExpressionOperator.initializeFunctionOperators(ExpressionOperator.java:1350)
	at org.eclipse.persistence.expressions.ExpressionOperator.initializeOperators(ExpressionOperator.java:1384)
	at org.eclipse.persistence.expressions.ExpressionOperator.&lt;clinit&gt;(ExpressionOperator.java:46)
	at com.haulmont.cuba.core.sys.persistence.EclipseLinkCustomizer.initTransientCompatibleAnnotations(EclipseLinkCustomizer.java:30)
	at com.haulmont.cuba.core.sys.AbstractAppContextLoader.beforeInitAppContext(AbstractAppContextLoader.java:49)
	at com.haulmont.cuba.desktop.sys.DesktopAppContextLoader.load(DesktopAppContextLoader.java:80)
	at com.haulmont.cuba.desktop.App.init(App.java:142)
	at com.company.grocery.desktop.App$1.run(App.java:11)
	at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.EventQueue.access$600(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.lang.NullPointerException: null
	at org.eclipse.persistence.indirection.IndirectCollectionsFactory.getProvider(IndirectCollectionsFactory.java:190)
	at org.eclipse.persistence.indirection.IndirectCollectionsFactory.&lt;clinit&gt;(IndirectCollectionsFactory.java:43)
	... 25 common frames omitted

it seems that you have installed JRE in your system and it has a version greater than 1.8+. Please check this information, because desktop webstart works only with 1.8+ version.

I changed the webstart configuration to be 1.8 only, and it still fails: I get the following exception:

	at jdk.javaws@10.0.1/com.sun.javaws.Launcher.relaunch(Unknown Source)
	at jdk.javaws@10.0.1/com.sun.javaws.Launcher.prepareResources(Unknown Source)
	at jdk.javaws@10.0.1/com.sun.javaws.Launcher.prepareAllResources(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart.prepareToLaunch(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart.prepareToLaunch(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart.launchApp(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart.launchApp(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart.continueInSecureThread(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart.access$000(Unknown Source)
	at jdk.plugin@10.0.1/sun.plugin2.main.WebStart$1.run(Unknown Source)
	at java.base/java.lang.Thread.run(Unknown Source)

Also, Java 9 and Java 10 are out, and if you try to run with 1.8, you receive another security exception… so the latest Java needs to be supported for desktop clients…



We are planning to support Java 11 LTS in the next major version 7.0. At the moment, Oracle supports only one LTS version of Java - Java 8. Versions 9 and 10 have only 6 months support period.

1 Like

But as I show, I am running with Java 8 - via webstart installed with Java 10 - which I believe is going to be fairly standard, so not having this work is going to be a problem…

Most Java deployments require updating Java - usually automatically - for security concerns.

As your exceptions shows, you use Java 10. For some reason it is set as default JRE on your PC.

Please re-read and look at the configuration. The Java 10 is installed, but it is configured to use Java 8 when running applications via WebStart, so even though I am attempting to run using java 8, it is failing - looks like when it is trying to launch the java 8 jvm - so something is incorrect in the JNLP file.

When I run the desktop app using Java8 from the command line it works correctly - it won’t launch using Java10 webstart even though the destination JVM is Java8.

Sorry, I missed the point that you want to launch 1.8 under 10 Web Start Launcher. Unfortunately, we have not tested this option yet. We will try to find the fix or configuration options.

Thank you. To clarify, we can tell a customer ‘you must have Java 8 installed…’, but we cannot tell a customer '‘you CANNOT have Java 9 or 10 installed’. They may be running other apps that require those versions, so using the ability to configure the java version via the JNLP and have it launch under java 10 using the Java 8 runtime is required.