JDK-5057141 : Java Web Start fails to download lots of applications: "unable to launch XXX"
  • Type: Bug
  • Component: deploy
  • Sub-Component: webstart
  • Affected Version: 5.0
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2004-06-03
  • Updated: 2004-06-09
  • Resolved: 2004-06-09
Related Reports
Duplicate :  
Description

Name: gm110360			Date: 06/03/2004


FULL PRODUCT VERSION :
java version "1.5.0-beta2"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-beta2-b51)
Java HotSpot(TM) Client VM (build 1.5.0-beta2-b51, mixed mode, sharing)

ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows XP [Version 5.1.2600]
Linux Suse 9.0

A DESCRIPTION OF THE PROBLEM :
A great number of JNLP app's fails to start on Windows and Linux, different machines and internet links. Download starts, and then terminates with message "unable to launch XXX"

-
It doesn't stop always at the same place, sometimes it dowloads a lot, sometimes almost nothing, and there are some apps that do work (eg Wurm online)

Lots of JGoodies samples dont work, and UVC client also. Similar exception hits some applets too.

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Hit some jnlp links on jgoodies or UVC. They will start downloading, and die in the middle of it.,

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
It should just work

ERROR MESSAGES/STACK TRACES THAT OCCUR :
JNLPException[category: Download Error : Exception: java.io.IOException: Stream closed. : LaunchDesc: null ]
	at com.sun.javaws.cache.DownloadProtocol$RetrieveAction.actionDownload(Unknown Source)
	at com.sun.javaws.cache.DownloadProtocol.doDownload(Unknown Source)
	at com.sun.javaws.cache.DownloadProtocol.getResource(Unknown Source)
	at com.sun.javaws.LaunchDownload.downloadJarFiles(Unknown Source)
	at com.sun.javaws.LaunchDownload.downloadEagerorAll(Unknown Source)
	at com.sun.javaws.Launcher.downloadResources(Unknown Source)
	at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
	at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
	at com.sun.javaws.Launcher.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)

or wrapped exception:
java.io.IOException: Stream closed.
	at java.net.PlainSocketImpl.available(Unknown Source)
	at java.net.SocketInputStream.available(Unknown Source)
	at java.io.BufferedInputStream.available(Unknown Source)
	at sun.net.www.MeteredStream.available(Unknown Source)
	at sun.net.www.http.KeepAliveStream.close(Unknown Source)
	at java.io.FilterInputStream.close(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.close(Unknown Source)
	at java.io.BufferedInputStream.close(Unknown Source)
	at java.io.BufferedInputStream.close(Unknown Source)
	at com.sun.javaws.net.BasicDownloadLayer.download(Unknown Source)
	at com.sun.javaws.cache.DownloadProtocol$RetrieveAction.actionDownload(Unknown Source)
	at com.sun.javaws.cache.DownloadProtocol.doDownload(Unknown Source)
	at com.sun.javaws.cache.DownloadProtocol.getResource(Unknown Source)
	at com.sun.javaws.LaunchDownload.downloadJarFiles(Unknown Source)
	at com.sun.javaws.LaunchDownload.downloadEagerorAll(Unknown Source)
	at com.sun.javaws.Launcher.downloadResources(Unknown Source)
	at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
	at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
	at com.sun.javaws.Launcher.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)



REPRODUCIBILITY :
This bug can be reproduced often.
(Incident Review ID: 275722) 
======================================================================

Comments
EVALUATION The real cause of the problem is we get a SocketException during the download of jar: java.net.SocketException: socket closed at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(Unknown Source) at java.io.BufferedInputStream.read1(Unknown Source) at java.io.BufferedInputStream.read(Unknown Source) at sun.net.www.MeteredStream.read(Unknown Source) at java.io.FilterInputStream.read(Unknown Source) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(Unknown Source) at java.io.BufferedInputStream.read1(Unknown Source) at java.io.BufferedInputStream.read(Unknown Source) at java.io.BufferedInputStream.read1(Unknown Source) at java.io.BufferedInputStream.read(Unknown Source) at java.io.FilterInputStream.read(Unknown Source) at com.sun.javaws.net.BasicDownloadLayer.download(BasicDownloadLayer.java:68) at com.sun.javaws.cache.DownloadProtocol$RetrieveAction.actionDownload(DownloadProtocol.java:417) at com.sun.javaws.cache.DownloadProtocol.doDownload(DownloadProtocol.java:602) at com.sun.javaws.cache.DownloadProtocol.getResource(DownloadProtocol.java:755) at com.sun.javaws.LaunchDownload.downloadJarFiles(LaunchDownload.java:729) at com.sun.javaws.LaunchDownload.downloadEagerorAll(LaunchDownload.java:652) at com.sun.javaws.Launcher.downloadResources(Launcher.java:967) at com.sun.javaws.Launcher.handleApplicationDesc(Launcher.java:335) at com.sun.javaws.Launcher.handleLaunchFile(Launcher.java:218) at com.sun.javaws.Launcher.run(Launcher.java:165) at java.lang.Thread.run(Unknown Source) Java Web Start code then catch the exception, call close on the input stream, which then cause the stack trace in the bug description. We should investigate into the root cause of this problem (SocketExcpetion thrown during jar download) first. The close problem is less critical. ###@###.### 2004-06-07 I can reproduce the problem outside of javawebstart. Attached is the test case in this bug. To reproduce the problem, run with tiger beta2: java test http://capoon.sfbay.sun.com:8080/client/client.jar And you will see exception: java.net.SocketException: socket closed at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(Unknown Source) at java.io.BufferedInputStream.fill(Unknown Source) at java.io.BufferedInputStream.read1(Unknown Source) at java.io.BufferedInputStream.read(Unknown Source) at sun.net.www.MeteredStream.read(Unknown Source) at java.io.FilterInputStream.read(Unknown Source) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(Unkn own Source) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(Unkn own Source) at test.main(test.java:38) The test basically does HEAD and GET request to the url specified for a few times, which is basically what java web start does to download jar files. If I run the test with 1.4.2, it will never throw such expcetion and always succeed. I can reproduce the bug on my windows2000 and winXP machine. The sever is tomcat 4.1.27 running on solaris. I tried 4.1.30 running on the windows, same behaviour. ###@###.### 2004-06-07 the networking part of the fix for 5039967 fixes this problem ###@###.### 2004-06-09
07-06-2004