I'm trying to create a https secure connection for my Java webstart application. All I did was to configure my Tomcat to use a certificate and I was done. I could just do
"https://nsjns:8443/abc/xyz.jnlp" and it downloaded my application and worked fine.
for production, we purchased a certificate and this cert was kept on the load balancer with the actual web server behind the load balancer. If I use the browser I can see the server and can download my jnlp file by typing the url in the browser. However, I cannot execute the jnlp file using Java webstart as I get the below exception.
Java.io.IOException: Server returned HTTP response code: 503 for URL: "http://test.tec.com/abc.jnlp"
at sun.reflect.GeneratedConstructorAccessor13.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1674)
at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1672)
at java.security.AccessController.doPrivileged(Native Method)
at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1670)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1243)
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(Thread.java:722)
Caused by: java.io.IOException: Server returned HTTP response code: 503 for URL: http://test.tec.com/abc.jnlp
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1625)
at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:468)
... 17 more
It is resolving my url from https to http. I'm new to all this. Please help me with your ideas and suggestions. What am I missing to do?
Unlikely to have anything to do with your certificate. Try using the IP address instead of the hostname in the webstart URL.
You don't say what platform you are running webstart on, but if the IP address works then launch the webstart control panel:
javaws -viewer
and go to Network Settings on the Java tab. Assuming it doesn't already say so, select Direct Connection (i.e. no proxy) and tell us if it works after that.