Dear Reader,
Just coming from having to push a Java Application out to the clients machine via Java Web Start. Everything went pretty well, after signing all the Jar’s. This, so they could sneak outside the “security sandbox” that Java Web Start plugs around downloaded applications.
The (maybe) unusual thing in our setup was, that the jnlp file had to be rendered on the fly. So there was never going to be a “on-disk” version of the file during the whole request, response cycle.
So, following the old “monkey see/monkey do” rule, my generated file looked a bit like this one:
[...]
jnlp spec="1.0+"
codebase="http://192.168.0.1/"
xhref="myapp.jnlp" mce_href="myapp.jnlp" // ignore the mce...
[...]
When trying to run this generated “file” through a link in the browser, silly web start tried to locate the file “http://192.168.0.1/myapp.jnlp”… HELLO? YOU ARE THIS FILE! STOP COMPLAINING YOU CANNOT FIND YOURSELF!
A quick look in the Java Web Start Tutorial hinted me to try to omit the href argument in the jnlp tag. Apparently, it is not needed. It then worked the way as I expected it to. But really, what is it good for anyway?
In the “spec” mentioned above, it says about the href attribute:
“The href specifies the URL of the JNLP file itself.”
Oh, that’s cute :-)
Thank you.