JDK-6885558 : cold start of JNLP webstart FX application fails
  • Type: Bug
  • Component: deploy
  • Sub-Component: webstart
  • Affected Version: 6u18
  • Priority: P1
  • Status: Closed
  • Resolution: Fixed
  • OS: windows
  • CPU: x86
  • Submitted: 2009-09-24
  • Updated: 2011-06-12
  • Resolved: 2009-12-01
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7
6u18 b03Fixed 7Fixed
Description
clear cache, install 6u18 b02.

launch any javafx webstart application, e.g:

javaws http://javafx.com/samples/BrickBreaker/webstart/BrickBreaker.jnlp

application won't start.  no error.

launch again, it works this time.

regression started in 6u18 b02.  b01 is okay.

performance team first noticed this when trying to get cold cache time for 6u18 b02.

Comments
EVALUATION Two problem here: 1. Problem is now with customized progress bar, we create the JNLPClassLoader a lot earlier, before we downloaded all JNLP files. Therefore when we create the JNLPClassLoader with the LD, it doesn't even have the extension desc set to it yet. That's why the JNLPClassLoader only has JARs listed in the main application JNLP. 2. There are issues with ignoreSigners performance flag when used with webstart. Looks like problem is we call setIgoreSigners before we grant permission. So when we later try to grant permission and need to use the certificate for checking, getCertificate will return null. Fix: 1. Download all JNLP files first before creating the JNLPClassLoader. This way the JNLPClassLoader will have all the JAR urls correctly. 2. Disable ignoreSigners in webstart case for now. Need to re-visit again in b04. (Things are changing in b04 with Jeff's mixed code fix in 6u17 anyway)
25-09-2009

EVALUATION Stack trace when bug is reproduced: (when app is not in cache, and FX runtime ins cache) basic: Main-class: com.sun.javafx.runtime.main.Main security: JAVAWS AppPolicy Permission requested for: http://javafx.com/samples/BrickBreaker/webstart/BrickBreaker.jar security: Add sandbox permissions security: JAVAWS AppPolicy Permission requested for: http://dl.javafx.com/javafx-rt-windows-i586__V1.2.1_b28.jar security: Istrusted: http://dl.javafx.com/1.2/javafx-rt.jnlp false network: Created version ID: 0+ network: Created version ID: 1.6 network: Created version ID: 1.6.0.18.ea network: Created version ID: 1.6 security: We were not granted permission, exiting java.lang.Exception: Stack trace at java.lang.Thread.dumpStack(Unknown Source) at java.lang.System.exit(System.java:904) at com.sun.javaws.Main.systemExit(Unknown Source) at com.sun.javaws.security.AppPolicy.grantUnrestrictedAccess(Unknown Source) at com.sun.javaws.security.AppPolicy.addPermissions(Unknown Source) at com.sun.jnlp.JNLPClassLoader.getPermissions(Unknown Source) at java.security.SecureClassLoader.getProtectionDomain(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$000(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at com.sun.jnlp.JNLPClassLoader.findClassHelper(Unknown Source) at com.sun.jnlp.JNLPClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at com.sun.javafx.runtime.main.Main.main(Main.java:35) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.sun.javaws.Launcher.executeApplication(Unknown Source) at com.sun.javaws.Launcher.executeMainClass(Unknown Source) at com.sun.javaws.Launcher.doLaunchApp(Unknown Source) at com.sun.javaws.Launcher.run(Unknown Source) at java.lang.Thread.run(Unknown Source) when both FX runtime and app not in cache: java.lang.NoClassDefFoundError: com/sun/javafx/runtime/Main at com.sun.javafx.runtime.main.Main.main(Main.java:35) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at com.sun.javaws.Launcher.executeApplication(Launcher.java:1649) at com.sun.javaws.Launcher.executeMainClass(Launcher.java:1595) at com.sun.javaws.Launcher.doLaunchApp(Launcher.java:1400) at com.sun.javaws.Launcher.run(Launcher.java:127) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.ClassNotFoundException: com.sun.javafx.runtime.Main at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at com.sun.jnlp.JNLPClassLoader.findClassHelper(JNLPClassLoader.java:387) at com.sun.jnlp.JNLPClassLoader.findClass(JNLPClassLoader.java:426) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) ... 10 more #### Java Web Start Error: #### null
24-09-2009