Note that there are some explanatory texts on larger screens.

plurals
  1. POJava WebStart with version Update
    text
    copied!<p>I'm using Java WebStart with this simple application that I'm working on and I have also made it so that it would be able to check for updates for the latest versions of the jar file. Although when running it, I get an error message saying that there is a missing version response from the server. </p> <p>below is my code for the jnlp file:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;jnlp spec="1.0+" codebase="http://localhost:8081/WebStartLauncher/app" href="Agecalc.jnlp"&gt; &lt;information&gt; &lt;title&gt;Jnlp Testing&lt;/title&gt; &lt;vendor&gt;Peter Ivan &amp; co&lt;/vendor&gt; &lt;homepage href="http://localhost:8081/WebStartLauncher" /&gt; &lt;description&gt;Testing Testing&lt;/description&gt; &lt;icon href="app/index.jpeg" kind="default"/&gt; &lt;icon kind="shortcut" href="app/index.jpeg" width="32" height="32"/&gt; &lt;offline-allowed/&gt; &lt;/information&gt; &lt;security&gt; &lt;all-permissions/&gt; &lt;/security&gt; &lt;resources&gt; &lt;j2se version="1.6+" /&gt; &lt;jar href="AgeCalc__V1.0.jar" version="1.0"/&gt; &lt;jar href="AgeCalc__V1.1.jar" version="1.1"/&gt; &lt;property name="jnlp.versionEnabled" value="true"/&gt; &lt;/resources&gt; &lt;application-desc main-class="com.webstart.AgeCalculator" /&gt; &lt;/jnlp&gt; </code></pre> <p>for the version.xml:</p> <pre><code>&lt;jnlp-versions&gt; &lt;resource&gt; &lt;pattern&gt; &lt;name&gt;AgeCalc__V1.0.jar&lt;/name&gt; &lt;version-id&gt;1.0&lt;/version-id&gt; &lt;/pattern&gt; &lt;file&gt;AgeCalc__V1.0.jar&lt;/file&gt; &lt;/resource&gt; &lt;/jnlp-versions&gt; </code></pre> <p>for the web.xml:</p> <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;web-app id="WebApp_ID" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"&gt; &lt;display-name&gt;WebStartLauncher&lt;/display-name&gt; &lt;welcome-file-list&gt; &lt;welcome-file&gt;webstart.jsp&lt;/welcome-file&gt; &lt;/welcome-file-list&gt; &lt;servlet&gt; &lt;servlet-name&gt;JnlpDownloadServlet&lt;/servlet-name&gt; &lt;servlet-class&gt;jnlp.sample.servlet.JnlpDownloadServlet&lt;/servlet-class&gt; &lt;/servlet&gt; &lt;servlet-mapping&gt; &lt;servlet-name&gt;JnlpDownloadServlet&lt;/servlet-name&gt; &lt;url-pattern&gt;/WebContent/WEB-INF/lib&lt;/url-pattern&gt; &lt;/servlet-mapping&gt; &lt;/web-app&gt; </code></pre> <p>and these are the error logs that i get:</p> <pre><code>com.sun.deploy.net.FailedDownloadException: Unable to load resource: (http://localhost:8081/WebStartLauncher/app/AgeCalc__V1.0.jar, 1.0) at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown Source) at com.sun.deploy.net.DownloadEngine.getCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.getCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.getResourceCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.getResourceCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.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.prepareLaunchFile(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$1.run(Unknown Source) at java.lang.Thread.run(Unknown Source) java.io.IOException: missing version response from server at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown Source) at com.sun.deploy.net.DownloadEngine.getCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.getCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.getResourceCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.getResourceCacheEntry(Unknown Source) at com.sun.deploy.net.DownloadEngine.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.prepareLaunchFile(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$1.run(Unknown Source) at java.lang.Thread.run(Unknown Source) </code></pre> <p>Please advise on how to proceed. Many thanks!</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload