connection refused exception when trying to run a jar via web start
<p>I am getting the following exception when trying to run my jar through java web start:</p>

<pre><code>com.sun.deploy.net.FailedDownloadException: Unable to load resource: http://localhost   /ValidatorWEB/validator.jnlp
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)
</code></pre>

<p>This is the wrapped exception:</p>

<pre><code>java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
</code></pre>

<p>Here is my .jnlp file:</p>

<pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;jnlp spec="1.0+" codebase="http://localhost/ValidatorWEB/" 
href="validator.jnlp"&gt;
&lt;information&gt;
    &lt;title&gt;Validator&lt;/title&gt;
    &lt;vendor&gt;My Company&lt;/vendor&gt;
&lt;/information&gt;
&lt;resources&gt;
    &lt;!-- Application Resources --&gt;
    &lt;j2se version="1.6+"
          href="http://java.sun.com/products/autodl/j2se"/&gt;
    &lt;jar href="WEB-INF/lib/validator.jar" main="true" /&gt;

&lt;/resources&gt;
&lt;application-desc
     name="Validator"
     main-class="webstartComponentArch.DynamicTreeApplication"
     width="300"
     height="300"&gt;
 &lt;/application-desc&gt;
 &lt;update check="background"/&gt;
</code></pre>

<p> </p>

<p>I am deploying the whole thing as a simple WAR to glassfish v2.1 on my <em>local machine</em>. The validator.jar is located in WEB-INF/lib and the jnlp and jsp page I am accessing the jnlp from is at the root of the ValidatorWEB folder.</p>

<p>Googling hasn't helped. I have tried turning my firewall off and it still does the same thing. I have the appropriate Mime-type set in Glassfish. Is there something else I'm forgetting to do?</p>
