我想使用webstart从浏览器启动一个程序,为此我有一个.jnlp文件,如下所示:
<?xml version="1.0" encoding="UTF-8"?>
<jnlp spec="1.0+"
codebase="http://localhost:8080/webstart/"
href="ncb-client.jnlp">
<information>
<title>Title</title>
<vendor>Vendor</vendor>
<homepage href="http://www.example.com/"/>
<description>Description</description>
<icon href="example.gif"/>
</information>
<resources>
<j2se version="1.7+" />
<jar href="MyProgram.jar"/>
</resources>
<security>
<all-permissions/>
</security>
<application-desc main-class="com.Mainclass">
<argument>server.address</argument>
<argument>rmi://localhost:1111?http=:8080</argument>
<argument>client.rmi.ssl.truststore</argument>
<argument>C:\keystore</argument>
我很确定.jnlp文件是正确的,因为它有一天工作,第二天不再工作 . 通过不工作我的意思是在Firefox而不是启动程序我只是在第二个选项卡中打开.jnlp文本 . 在Chrome中,我在另一个标签中看到了这个:
Vendor Title server.address description server.address rmi://localhost:1111?http=:8080 client.rmi.ssl.truststore C:\keystore
我不知道系统从一天到另一天有什么变化,没有我改变任何东西 . 如果我尝试执行jnlp,我会得到以下异常,当然应用程序无法启动:
java.io.IOException: Invalid Http response
任何人都可以想到我做错了或者在我的系统中可以改变以使其不起作用的东西吗?
1 回答
感谢您的帮助,您的一些答案通过进一步思考帮助我找到了问题 . 问题是Web服务器发生了更改,不再正确地提供.jnlp文件 .