JDK-6680615 : java web start cannot launch/import component-desc jnlp file
  • Type: Bug
  • Component: deploy
  • Sub-Component: webstart
  • Affected Version: 6u10
  • Priority: P1
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2008-03-26
  • Updated: 2010-09-17
  • Resolved: 2008-04-03
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
6u10 b21Fixed 7Fixed
Description
javaws -import http://nicole1.sfbay.sun.com:8080/JavawsMustangIntegTest/cacheViewer/CacheViewer_Library.jnlp

or 

javaws http://nicole1.sfbay.sun.com:8080/JavawsMustangIntegTest/cacheViewer/CacheViewer_Library.jnlp

both fail with:

java.lang.Exception: Internal Error: Internal error, no JREDesc and no JREInfo
	at com.sun.javaws.Launcher.prepareLaunchFile(Launcher.java:400)
	at com.sun.javaws.Launcher.prepareToLaunch(Launcher.java:198)
	at com.sun.javaws.Launcher.launch(Launcher.java:111)
	at com.sun.javaws.Main.launchApp(Main.java:306)
	at com.sun.javaws.Main.continueInSecureThread(Main.java:210)
	at com.sun.javaws.Main$1.run(Main.java:107)
	at java.lang.Thread.run(Unknown Source)

Comments
SUGGESTED FIX The root cause was my misconception, where I assumed component-desc cannot be launched, and that having a JREDesc is mandatory. The truth is, JREDesc's are optional for any launch type, which wasn't even the case in the b13 implementation. That's why I was confused. Thanks to Andy's clarification, DefaultMatchJRE now uses a default JREDesc with VersionID '0+', when starting the traversal. This ensures we have the default minimum selection 0+, which means any JRE. I used this opportunity to clarify LaunchSelection's selectJRE, i.e. made it protected and moved both, LaunchSelection and DefaultMatchJRE into the sub-packge 'jnl', where it semantically belongs. To select a JRE, we always have to call LaunchDesc.selectJRE(). This fixes this CR, plus: - allows any JNLP files without a JREDesc +++ testcase: http://j2se.east.sun.com/deployment/www/tests/1.6.0_10/6680615/
27-03-2008

EVALUATION component-desc is not required to have JREDesc. when invoking javaws on a jnlp file with component-desc, the behaviour should be the same as "javaws -import". we should just download the JARs and exit.
26-03-2008