Heyho,
we have an application working with jre 1.5 which can be used online or offline.
1. Users start it once while being online and then application is stored in the java cache
2. After that the application can also be used offline
3. A user then starts a Batch file which contains the following:
javaws "http://www.example.net/sfp-offline.jnlp"
So while using jre 1.5.0_14 javaws checks (i guess) the cache and finds the application and starts it.
Now if i start the batch file under 1.6.0_16 (also tried 1.6.0_13,_14,_18) the following exception occurs.
However if i start it from the cache viewer it works. So somehow 1.6 can not find it in the cache?
+CouldNotLoadArgumentException[ Could not load file/URL specified: http://www.example.net/sfp-offline.jnlp]+
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)
HERE:
java.net.ConnectException: Connection timed out: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
[... some more]
I read alot in the forum and some threads/bugs seem related:
[Cannot run offline unless launched from Cache Viewer|http://forums.sun.com/thread.jspa?forumID=38&threadID=786217]
or
[CouldNotLoadArgumentException when starting an updated JWS application|http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6563938]
However things are a bit different in my case.
I thought about changing the jnlp file however it seems that the file is not found in the cache in the first place?
Here's the jnlp file
<jnlp
spec="1.0+"
codebase="http://www.example.net/"
href="http://www.example.net/sfp-offline.jnlp">
<information>
<title>Example</title>
<vendor>Company</vendor>
<hompepage href="http://www.example.net/"/>
<description>Description (offline)</description>
<icon href="icon.gif"/>
<icon kind="splash" href="splash.gif"/>
<offline-allowed/>
</information>
<security>
<all-permissions/>
</security>
<resources>
<property name="user.timezone" value="Europe/Berlin"/>
<j2se href="http://java.sun.com/products/autodl/j2se" version="1.5.0_14" max-heap-size="512m"/>
<nativelib href="lib/someLib.jar"/>
<nativelib href="lib/someOtherLib.jar"/>
<jar href="lib/help.jar"/>
<jar href="lib/sfp.jar" main="true"/>
<jar href="lib/3rdParty.jar"/>
<jar href="lib/lotsOfOtherLibs.jar"/>
<jar href="lib/evenMoreLibs-9.8.7.jar"/>
</resources>
<application-desc main-class="main.Start">
<argument>-someFancyArguments</argument>
</application-desc>
</jnlp>
Thanks for any hints!
ToM
PS: The one thread is talking about "+This was actually a bug in 1.5 that was fixed in 1.6. In 1.5, it was possible to create a link to an online only application, and then launch it even if you were offline.+" Could this may be the case here?