A Look at HotJava
This week we're going to check out one of the oldest, most venerable Java applications in the world: HotJava.
For those of you who didn't know, Sun's HotJava is not just the first Web browser that supported Java applets. In fact, it's a Web browser written entirely in Java. This is no small feat. In fact, depending on how you read it, this application heralds proof of the success, or failure, of Java as a computing environment.
What makes us offer such a bold statement? There's always been debate and misunderstanding about Java's "purpose" in the world. A good number of people probably still hold the belief that it exists simply for making little toys to add to Web pages. We won't argue that it's useful (and widely used) to deck out HTML, but it would be foolish to assume Sun wants its success to end there.
In principle, applets are only an offshoot of the Java technology. Indeed, in principle, the idea of being able to write applications in a powerful high-level language, that will run on every major platform without further ado, is attractive in any development venue. Sun, as we've spoken about in a previous issue, has been busy creating markets for Java as quickly as it can think of them. Certainly the most obvious one would be licensing the Java environment to software developers who want to write whole applications in Java.
There are already some players entering the arena, for example, Corel, with an impressively quick preview release of an office software suite written in 1.0 Java. Certainly an anomaly among Java applets we've seen, their product weighs in at almost three megabytes. As of the time of this writing, it suffered from serious speed problems and was far from complete, but the core of the product is there--and it's a real set of applications (Wordperfect and Quattro Pro) that run in your Web page, whether you're on a Macintosh, Windows, or Unix machine. An accomplishment, certainly.
Speed is the primary concern of any developer considering Java for a project. And, in examining the body of available large-scale Java applications out there, we find it to be a legitimate one.
We say that HotJava 1.0 could prove that Java applications could be successful. Why? It's a real, working Web browser with an impressive set of features. Certainly it works better than a number of Netscape competitors we've seen. It does HTML 3.2, SSL, SOCKS, tables, and frames without a problem. In fact, it's got most of the Netscape features, with notable exceptions being JavaScript and the tag. It's the first and, at the moment, only Web browser to have complete support for the new Java standard. The technology behind the browser is are also wonderful.
The benefits of a well-organized Java program are innumerable, and in this case we can, for instance, easily and trivially write Java classes to implement new "handlers" for various MIME content types and network protocols. Or we can completely reconfigure the most minute details of the interface, or even reconfigure the HTML interpreter. This degree of easy flexibility and generality is unheard of among Web browsers and, in fact, among most commercial-grade applications.
We could also say that HotJava 1.0 is a serious warning about Java's future. Why? Because it's slow. We hate to say it, but it is. We did our testing on two "average" machines, a pentium 100 with 16 megabytes of RAM and a SPARCclassic (running Solaris 2.5.1) with 48 megabytes of RAM, and were about equally disappointed with both.For a software package being advertised as "lightweight" and with a "small footprint," and for having the benefit of a big performance-oriented rewrite of the JDK, it was barely usable on these "baseline" workstations. Subjectively, pages sometimes took 30 seconds to draw. Watching it ponderously render even plain HTML text paragraph by paragraph, pausing for an extra second to draw in the scrollbar when the window filled, became very painful very quickly.
What does it all boil down to? Efficiency is always the primary concern with systems like Java--and Java, although very promising, is not ready today for applications of scale. But let's put this in perspective.Java is still very new, and the large applications developed for it are still in their infancy. As HotJava emerges from beta into a final release (this is scheduled to happen this month), we're likely to see the speed problem addressed. But more than that, we're forced to reflect that the amount of progress JavaSoft has made toward its goal is nothing short of impressive.
For what it does, HotJava is, if not a finished product, probably a major step forward. Although not ready for the big time yet, this technology appears very close.
Join us next week for more details about the new AWT in JDK 1.1.