Java Web Start

This may not be the greatest of choices for forum, but I know the folks round here have used Java Web Start.

As we know, I’m not very bright, and I don’t read technical stuff very well. So, does anyone know of simple tutorial/example of using java web start?

Thanks in advance for any help,

Kev

Take any of the webstart apps around and read the JNLP files. Most applications are really easy and the JNLP file is easy to read.

For the rest:

http://www.vamphq.com/

this is what my jnlp webstart file looked like, and it worked. The filename is the same as the program.jar file, in this case Bricker2.jnlp

<?xml version="1.0" encoding="UTF-8"?>

<jnlp spec=“1.0+”
codebase=“http://afweb.hit.no/~u022304/

Bricker2 v0.2 Martin Seterstoen Tech/demo version of Bricker2

In a similar vein:

anyone have a reference for how to package a .jar file and prepare a .jnlp file so that you can do incremental updates? By incremental, I mean that if I add a new resource to a .jar, only that resource is downloaded and added to the existing jar, as opposed to downloading the whole file.

Sorry, doesn’t work that way. HTTP is an all or nothing protocol, so webstart needs to download the entire file if it changes. If you’re expecting a lot of changes, split your program into lots of JAR files.

Yes it does work that way. :slight_smile:

But you require more support on the server side… have to use the jardiff utility etc… I don’t know enough details. I think you can get a servlet from the web start pages that does most of what you need on the server side.

More details are here:
http://java.sun.com/products/javawebstart/1.2/docs/downloadservletguide.html

The relevant part is:

[b]Automatic JARDiff generation[/b]
[b]The servlet will automatically generate and return incremental updates to JAR files, if possible.[/b] If the current-version-id parameter is included in the request and the servlet can find both a match on the current-version-id and the requested version (given the above matching rules) and the request is for a JAR file (e.g., the target resource has the .jar extension), then a JARDiff file will be generated by the servlet. The JARDiff file is returned as long as its size is less than that of the requested version.

The JARDiff file is generated and stored in a temporary directory that is specific to the given Web container. The servlet locates the temporary working directory using the javax.servlet.context.tempdir context attribute.

Well that’s new. Looks like you generate a delta or “patch” jar for webstart to use to override the original jar. Smart.

Yeah it sounds quite cool… I wish I knew how to make it go. ;D