Thursday, August 09, 2007

Java Web Start

Java Web Start is a technology by Sun Java. It does not change the way the Java applications are created but changes the way they are deployed and run on the desktops. It is not for the browser based applications (or is it???) but only for thick clients.

If you have a Java thick client application and you are always chided for the overheads involved in deployment, the environment set up, the upgrades and the security concerns, Java Web Start is for you. Main advantage of Web Start over applets is that this overcome the compatibility problems with the browser's Java plugins and different JVM versions.

Installing the application is a matter of putting the application code base in a web server and clicking on the URL. The application as well as the required JRE are automatically installed. The new JRE version if installed is used only for this application by Java Web Start and does not affect any other JRE in the desktop.

Upgrades to the application is just updating the jars on the web server which houses the application code base and the next time the application on the client desktop is launched the new updates are automatically downloaded into the desktop and the new version on the application is launched.

If you are concerned on security, two buzz words "Sandbox" and "Signed JAR" are for you. Sandbox is a controlled environment with in the scope of the JWS and the application can access resources only in that. Any access to the file system or to the network is restricted.

If this sounds as a restriction and you trust your users to make conscious decisions, do not panic, you have a way to get around. You can sign the jars digitally and if the users acknowldge and accept the digital certificate before the application is launched, the application can have anywhere between the restricted to unlimited access to the resources based on the permissions configured in the JNLP xml file.

Wait a minute, What is JNLP? This is the protocol, the API and the specification that makes the Java Web Start Technology work. It expands as Java Network Launching Protocol.

More on JNLP :
http://jcp.org/en/jsr/detail?id=56

More on JWS:
http://java.sun.com/j2se/1.5.0/docs/guide/javaws/index.html

References :

http://java.sun.com/developer/technicalArticles/WebServices/JWS_2/JWS_White_Paper.pdf

http://en.wikipedia.org/wiki/Java_Web_Start

No comments: