3 Replies Latest reply: Aug 10, 2012 10:48 AM by 817264 RSS

    Web Start Application not running with JRE7 but runs in JRE 6

    955022
      We have web start application which was running fine in java 6,but in Java 7 it throws java.net.SocketException: Unexpected end of file from server. I enabled tracing and captured the logs.

      OS: Windows 7.

      JRE 6
      ------------------------------------------------------------------------------------------------------------------------------------------------------------------
      network: prepareToLaunch: offlineOnly=false
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Connecting http://10.220.69.251:80/conf/WebNMS.jnlp with proxy=DIRECT
      network: Connecting socket://10.220.69.251:80 with proxy=DIRECT
      network: ResponseCode for http://10.220.69.251:80/conf/WebNMS.jnlp : 200
      network: Encoding for http://10.220.69.251:80/conf/WebNMS.jnlp : null
      network: Sever response: (length: 5367, lastModified: Sun Jul 10 00:24:31 IST 2011, downloadVersion: null, mimeType: application/x-java-jnlp-file)
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Downloading resource: http://10.220.69.251:80/conf/WebNMS.jnlp
           Content-Length: 5,367
           Content-Encoding: null
      network: Wrote URL http://10.220.69.251:80/conf/WebNMS.jnlp to File C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\5\130a76c5-1abb24cf-temp
      network: Disconnect connection to http://10.220.69.251:80/conf/WebNMS.jnlp
      network: CleanupThread used 19130 us
      network: CleanupThread used 3 us
      network: Cache: Enable a new CacheEntry: http://10.220.69.251:80/conf/WebNMS.jnlp
      network: Downloaded http://10.220.69.251:80/conf/WebNMS.jnlp: C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\5\130a76c5-1abb24cf

      -------------------------------------------------------------------------------------------------------------------------------------------------------------------

      JRE 7
      ------------------------------------------------------------------------------------------------------------------------------------------------------------------
      network: prepareToLaunch: offlineOnly=false
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Cache entry not found [url: http://10.220.69.251:80/conf/WebNMS.jnlp, version: null]
      network: Connecting http://10.220.69.251:80/conf/WebNMS.jnlp with proxy=DIRECT
      network: Connecting socket://10.220.69.251:80 with proxy=DIRECT
      network: Connecting socket://10.220.69.251:80 with proxy=DIRECT
      java.net.SocketException: Unexpected end of file from server
           at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
           at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
           at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
           at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
           at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
           at java.net.HttpURLConnection.getResponseCode(Unknown Source)
           at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown Source)
           at com.sun.deploy.net.BasicHttpRequest.doGetRequestEX(Unknown Source)
           at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown Source)
           at com.sun.deploy.net.DownloadEngine._downloadCacheEntry(Unknown Source)
           at com.sun.deploy.cache.ResourceProviderImpl.getResourceCacheEntry(Unknown Source)
           at com.sun.deploy.cache.ResourceProviderImpl.getResourceCacheEntry(Unknown Source)
           at com.sun.deploy.cache.ResourceProviderImpl.getResource(Unknown Source)
           at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
           at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
           at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
           at com.sun.javaws.Launcher.launch(Unknown Source)
           at com.sun.javaws.Main.launchApp(Unknown Source)
           at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
           at com.sun.javaws.Main.access$000(Unknown Source)
           at com.sun.javaws.Main$1.run(Unknown Source)
           at java.lang.Thread.run(Unknown Source)
      network: Connecting http://10.220.69.251:80/conf/WebNMS.jnlp with proxy=DIRECT
      network: Connecting socket://10.220.69.251:80 with proxy=DIRECT
      network: Connecting socket://10.220.69.251:80 with proxy=DIRECT
      java.net.SocketException: Unexpected end of file from server
           at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
           at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
           at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)
           at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)
           at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
           at java.net.HttpURLConnection.getResponseCode(Unknown Source)
           at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown Source)
           at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown Source)
           at com.sun.deploy.net.BasicHttpRequest.doGetRequest(Unknown Source)
           at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown Source)
           at com.sun.deploy.net.DownloadEngine._downloadCacheEntry(Unknown Source)
           at com.sun.deploy.cache.ResourceProviderImpl.getResourceCacheEntry(Unknown Source)
           at com.sun.deploy.cache.ResourceProviderImpl.getResourceCacheEntry(Unknown Source)
           at com.sun.deploy.cache.ResourceProviderImpl.getResource(Unknown Source)
           at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
           at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
           at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
           at com.sun.javaws.Launcher.launch(Unknown Source)
           at com.sun.javaws.Main.launchApp(Unknown Source)
           at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
           at com.sun.javaws.Main.access$000(Unknown Source)
           at com.sun.javaws.Main$1.run(Unknown Source)
           at java.lang.Thread.run(Unknown Source)
      preloader: Construct preloader delegate
      network: Connecting socket://127.0.0.1:51160 with proxy=DIRECT
      #### Java Web Start Error:
      #### Unable to load resource: http://10.220.69.251:80/conf/WebNMS.jnlp
      ------------------------------------------------------------------------------------------------------------------------------------------------------------------

      Can somebody figure out what's going wrong. thanks in advance.

      Regards
      Madhava
        • 1. Re: Web Start Application not running with JRE7 but runs in JRE 6
          gimbal2
          "works in java 6, doesn't work in java 7, SocketException".

          Java 7 defaults to IPv6. You might want to try forcing IPv4 to see if that changes anything. But I have no idea how to do that through webstart, you'd have to google it.
          • 2. Re: Web Start Application not running with JRE7 but runs in JRE 6
            955022
            thanks, But the issue doesn't seem to be with IPVersion. I tried setting the java option in java web start console to -Djava.net.preferIPv4Stack=true , still same error. Another funny thing is that,it works fine when deployed in https or port other than 80 without setting any java option.

            JRE7 -HTTPS server
            ---------------------------------------------------------------------------------------------------------------------------------------------------------------------
            network: prepareToLaunch: offlineOnly=false
            network: Cache entry not found [url: https://10.220.5.106:444/conf/WebNMS.jnlp, version: null]
            network: Cache entry not found [url: https://10.220.5.106:444/conf/WebNMS.jnlp, version: null]
            network: Cache entry not found [url: https://10.220.5.106:444/conf/WebNMS.jnlp, version: null]
            network: Connecting https://10.220.5.106:444/conf/WebNMS.jnlp with proxy=DIRECT
            network: Connecting socket://10.220.5.106:444 with proxy=DIRECT
            security: Loading Root CA certificates from C:\Program Files\Java\jre7\lib\security\cacerts
            security: Loaded Root CA certificates from C:\Program Files\Java\jre7\lib\security\cacerts
            security: Loading SSL Root CA certificates from C:\Program Files\Java\jre7\lib\security\cacerts
            security: Loaded SSL Root CA certificates from C:\Program Files\Java\jre7\lib\security\cacerts
            security: Loading Deployment SSL certificates from C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\security\trusted.jssecerts
            security: Loaded Deployment SSL certificates from C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\security\trusted.jssecerts
            security: Loading certificates from Deployment session certificate store
            security: Loaded certificates from Deployment session certificate store
            security: Loading certificates from Internet Explorer ROOT certificate store
            security: Loaded certificates from Internet Explorer ROOT certificate store
            security: Checking if certificate is in Deployment denied certificate store
            security: Checking if certificate is in Deployment session certificate store
            security: Checking if SSL certificate is in Deployment permanent certificate store
            network: ResponseCode for https://10.220.5.106:444/conf/WebNMS.jnlp : 200
            network: Encoding for https://10.220.5.106:444/conf/WebNMS.jnlp : null
            network: Sever response: (length: 5396, lastModified: Fri Aug 10 17:59:21 IST 2012, downloadVersion: null, mimeType: application/x-java-jnlp-file)
            network: Cache entry not found [url: https://10.220.5.106:444/conf/WebNMS.jnlp, version: null]
            network: Downloading resource: https://10.220.5.106:444/conf/WebNMS.jnlp
                 Content-Length: 5,396
                 Content-Encoding: null
            network: Wrote URL https://10.220.5.106:444/conf/WebNMS.jnlp to File C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\58\69116ba-74c66a34-temp
            network: Disconnect connection to https://10.220.5.106:444/conf/WebNMS.jnlp
            network: CleanupThread used 8633 us
            network: Cache: Enable a new CacheEntry: https://10.220.5.106:444/conf/WebNMS.jnlp
            network: CleanupThread used 1 us
            network: Downloaded https://10.220.5.106:444/conf/WebNMS.jnlp: C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\58\69116ba-74c66a34
            temp: new XMLParser with source:


            ------------------------------------------------------------------------------------------------------------------------------------------------------------------

            jre7 port 1030
            -------------------------------------------------------------------------------------------------------------------------------------------------------------------
            network: prepareToLaunch: offlineOnly=false
            network: Cache entry not found [url: http://10.220.5.164:1030/conf/WebNMS.jnlp, version: null]
            network: Cache entry not found [url: http://10.220.5.164:1030/conf/WebNMS.jnlp, version: null]
            network: Cache entry not found [url: http://10.220.5.164:1030/conf/WebNMS.jnlp, version: null]
            network: Connecting http://10.220.5.164:1030/conf/WebNMS.jnlp with proxy=DIRECT
            network: Connecting socket://10.220.5.164:1030 with proxy=DIRECT
            network: ResponseCode for http://10.220.5.164:1030/conf/WebNMS.jnlp : 200
            network: Encoding for http://10.220.5.164:1030/conf/WebNMS.jnlp : null
            network: Sever response: (length: 5369, lastModified: Fri Aug 10 12:27:38 IST 2012, downloadVersion: null, mimeType: application/x-java-jnlp-file)
            network: Cache entry not found [url: http://10.220.5.164:1030/conf/WebNMS.jnlp, version: null]
            network: Downloading resource: http://10.220.5.164:1030/conf/WebNMS.jnlp
                 Content-Length: 5,369
                 Content-Encoding: null
            network: Wrote URL http://10.220.5.164:1030/conf/WebNMS.jnlp to File C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\61\2fc75bfd-7eb0ea26-temp
            network: Disconnect connection to http://10.220.5.164:1030/conf/WebNMS.jnlp
            network: Cache: Enable a new CacheEntry: http://10.220.5.164:1030/conf/WebNMS.jnlp
            network: Downloaded http://10.220.5.164:1030/conf/WebNMS.jnlp: C:\Users\tpargain\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\61\2fc75bfd-7eb0ea26
            temp: new XMLParser with source:
            -------------------------------------------------------------------------------------------------------------------------------------------------------------------
            • 3. Re: Web Start Application not running with JRE7 but runs in JRE 6
              817264
              Use WireShark/Fiddler or any other http sniffer to capture request/response headers.
              Is there anything different between 6 and 7? between 7 and port 80 and port 1030?
              What is the last request/response header pair before 7 fails?