Sign In/My Account | View Cart  

advertisement

AddThis Social Bookmark Button

Listen Print


I've been thinking about Java 2, and thinking about what I'd really like in an operating system (OS). My conclusion is that there will soon be a demand for an efficient, streamlined OS that runs Java 2 and has an outstanding interface. In this article, I'll explain the thinking that led me to this conclusion and ask for yourfeedback.

Bring On the Big Applications

The Java platform is ready for prime time. Java 2 sports an impressive battalion of APIs that can do almost anything you can imagine. As a platform, Java has finally matured to the point where serious applications are possible. It's clear to me that applications like Photoshop, FrameMaker, and (Heaven forbid) Word can now be written in Java.

Recreating existing applications in Java is really only a first step. The Java platform has features that enable new kinds of applications andways of thinking (JINI comes to mind). If Java takes over the world, as it seems poised to do,it will probably be in some totally unexpected way. Java's destiny maybe to run on small devices, like wireless telephones, pagers, VCRs, and toasters.

In the meantime, however, we've all still got desktop machines and applications we like to run, like web browsers and word processors. Now that Java 2 is out, desktop applications will migrate to the Java platform. The stability and advanced capabilities of Java 2 make the promise of Write Once, Run Anywhere finally come true.

Throw That Old OS in the Dumpster

If, someday soon, all the applications you want are in Java, then you'll have no reason to keep your existing OS. You wouldn't even care if you were running Windows or Solaris, so long as you had your Java environment on top of the OS. This was part of the original appeal of Java, that it might someday make Windows irrelevant. With Java 2, this dream might finally be coming true.

Once the OS is irrelevant, you might as well remove it entirely as a distinct entity. Instead, why not fold the OS and the Java environment together? Right now, the Java environment runs as a process inside some OS. An OS with a built-in JVM can make much more efficient use of memory and processing power to run Java applications.

This is not a new idea. Sun has something called JavaOS, and there's an open source solution in development called JOS. Neither of these solutions, however, has the right combination of features to appeal to the majority of desktop users.

Dear Santa

What features would a good Java-based operating system have? This is what I'd like to see:
  • Full support for Java 2.
  • Great interface. An OS without a good interface will find only limited acceptance. Linux has done very well, but it appeals primarily to Unix hacker types with long beards and sandals. To create a widely popular OS, you need to put a friendly, intuitive graphic user interface (GUI) on it.
  • Efficient. The OS should use little memory and run fast.
  • Free. Netscape and Microsoft have demonstrated that the quickest way to take over the world is by giving something away.

Surely This OS Already Exists?

I don't think I'm asking for a lot, but no existing solution satisfies me. Let's look at four candidates:

JavaOS

JavaOS lacks two important features. First, it's not free. Second, it doesn't have a GUI of its own. It's not really a complete product, but something that Sun allows companies to buy and adapt for thin clients or network computers. Only an OS that comes shrink-wrapped and ready to install and run on a PC will gain widespread acceptance.
JOS
This is almost what I want, but it seems to be far from done. It's an open source project, and aims to be easy to use and efficient. The project is undergoing reorganization right now; there isn't currently anything you can download and run.
Linux + Java 2
Linux is free to distribute, right? And it's relatively small and efficient. If you plop JDK 1.2 on top of it, it's pretty close to what I'm looking for. But it's top-heavy. The Java environment still runs as a process, on top of the OS. Furthermore, you need to install X Windows to use any of the GUI stuff. Linux plus X Windows plus Java 2 is getting to be a big heap of software, so it's probably not terrifically efficient and certainly not compact. Also, Linux lacks an easy, intuitive GUI, although it's conceivable one could be built with Swing.
Kaffe
For completeness, I'll mention Kaffe, a PersonalJava 1.1 environment developed independent of Sun. Because it was independently developed, it's free from Sun's royalties and license restrictions. It's not an operating system, just an implementation of Java that sits on top of an operating system. Still, it's got some pretty amazing properties: it can run on a 4 Mb DOS machine and the entire source tree fits on a floppy disk. But it isn't Java 2, and it isn't an OS; it's a step in the right direction.

Dueling Licenses

It shouldn't be that hard to write a Java-based operating system. After all, the source code for an operating system (Linux) and the source code for Java 2 are both available. Probably two good developers could accomplish the job in less than a year, working full time. The JOS project is wagering that many developers working part time will be able to do the job.

But an important issue, and one upon which JOS is still undecided, is the question of license. Free software comes with a license. If you actually did merge the Linux source code with the Java 2 source code, what license would it have? Probably both. Linux comes with the GNU Public License (GPL), which says that any software developed using its source code must also fall under the GPL. The Java 2 source code comes with Sun's Community Source license, which stipulates that (1) if you charge for software developed with Sun's source code, you must pay Sun some money, and (2) the software you develop must pass Sun's compatibility tests for Java.

Any Java-based OS (including JOS) will have to deal with these issues. If you write your own OS from the ground up, you can choose any license you want and forget about Linux's GPL. If you write your own Java implementation from the ground up, you could forget about Sun's Community License. While it might make sense to write your own OS, it's probably foolish to try to rewrite Java.

Is It Soup Yet?

The world will soon be asking for a good OS that runs Java 2, but there isn't one yet. JOS seems like the best bet, but it's got an uncertain future. One or two full time programmers would inject a lot of life into the project, but let's face it, we've all got day jobs.

What do you think? Is a Java-based OS a good idea? Does the world really need it? Is there a solution I don't know about? Write me some email and tell me what you think.


Jonathan Knudsen is a staff writer for O'Reilly & Associates. He is the author of Java Cryptography and Java 2D Graphics and writes a monthly column called Bite-Size Java.