United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6898437 Java Web Start 6 does not return appropriate exit code upon failure
JDK-6898437 : Java Web Start 6 does not return appropriate exit code upon failure

Details
Type:
Enhancement
Submit Date:
2009-11-05
Status:
Closed
Updated Date:
2010-12-04
Project Name:
JDK
Resolved Date:
2010-08-03
Component:
deploy
OS:
windows_vista,windows_xp
Sub-Component:
webstart
CPU:
x86
Priority:
P3
Resolution:
Fixed
Affected Versions:
6u16
Fixed Versions:
6u21-rev (b08)

Related Reports
Backport:
Backport:
Backport:
Duplicate:
Relates:

Sub Tasks

Description
Java Web Start 1.4.2 returned "-1", when an error was encountered
during download or application start of a Java Web Start application. 
Otherwise, if everything went fine, "0" was returned.

Java Web Start 6 always returns "0", no matter, if there was a 
problem encountered during download or application start or not.

                                    

Comments
EVALUATION

I don't think we docuemented on the usage of javaws return value.  It's never a supported/tested feature.

we should investigate this for 6u20.
                                     
2009-11-05
WORK AROUND

Use JNLP DownloadService API to perform the JARs download instead, which will throw exception if download fails ?
                                     
2009-11-05
EVALUATION

Anytime JWS6 encounters a launch issue - it exits with code of 0. This is different behaviour to 1.4.2 JWS and should be corrected. We should indicate errors with exit code of -1.
                                     
2009-11-20
EVALUATION

This usage of the private interface between javaws.exe and com.sun.javaws.Main is usage of a private interface and completely unsupported.
Although I agree we should make the change suggested in an update release, even making this change could be considered a regression from 1.5.0 and earlier jdk6 updates.
I do not see this qualifys as a show-stopper for 6u18, and am reprioritizing as P3.
                                     
2009-12-01
SUGGESTED FIX

two error returns call Main.systemExit(0).
1.) in Main.java, when importing with cache disabled, the other
2.) in LaunchErrorDialog, if exit flag specified
both need to be changed to SystemExit(-1) to provide this compatibility.
                                     
2010-03-15



Hardware and Software, Engineered to Work Together