|
Starting Java Applications
from the Web
Write a Java Web Start app that packages JAR and data files, which download automatically at startup with no impact on performance
by James W. Cooper
Posted April 14, 2004
Dave Barry once mused about the sugary cereal in the picture on TV being "part of a balanced breakfast." He claimed it really means adjacent to a balanced breakfast—the other tempting foods in the picture—and is about as relevant as a can of shaving cream or a dead bat. That's the way I used to feel about Java Web Start technology. It didn't seem important or relevant—it was just this other weird thing on the table.
Now I see it as a little more important. Java Web Start allows you to post complete Java applications and their data on a Web site and run them seamlessly, either from the Web or in stand-alone fashion. If your client computer is connected to the Web, the Web Start system will check automatically for updates, and, if not, it will run independently.
This sounded a little daft to me at one time, but of course there are lots of cases where a Java application is more useful than embedding something messy in a Web site applet. In fact, running Java applications with automatic updates is really the best of both worlds. I finally came to my senses when I had a fairly complicated application involving data handling, graphics, and a large XML data set that I needed to be able to demonstrate to interested users at various locations not nearby my own office. I didn't want or need to travel somewhere just to run a simple demo, but I wanted to make sure that they had the same visual experience on their computer system that I did. In other words, I wanted to make sure that the code worked there too, as well as it did on my laptop or desktop machine.
Java Web Start allows you to package a system of any number of JAR files and data files and start the system when they are all downloaded. Moreover, if the data you want to include is voluminous, like XML data often is, you can create a compressed JAR file, which will make the download much faster, but hardly affect the performance at all.
Back to top
|