Open Source Java: Interview with an Apache Harmony Project Founder
Maria Winslow
LinuxPlanet
February 27, 2006
Harmony, an open source Java implementation, is currently in incubator status at the Apache Software Foundation. The Harmony project mission is to create a compatible, independent implementation of J2SE 5 under the Apache License v2, and "create a community-developed modular runtime (VM and class library) architecture to allow independent implementations to share runtime components, and allow independent innovation in runtime components."
There is a lot of open source activity currently surrounding Java, from JBoss and Geronimo (open source application servers) to MyFaces and Spring (open source web application frameworks), but Java itself is the last proprietary piece of the puzzle. If Harmony is successful, will Sun still matter?
I asked Dalibor Topic, one of the project founders, to tell us more about the history of the project, its importance to the Java community, and plans for the future.
LinuxPlanet: How did the Harmony project get started?
Dalibor Topic: Not being an Apache Software Foundation member, I can not speak authoritatively on the early history on Apache's side, so I'll give you a personal account of how we started to build the bridges that led to Apache Harmony. I am a co-maintainer of the Kaffe.org virtual machine, and a developer on the GNU Classpath class library project, which are both long running sister projects to provide a full free software Java implementation.
In 2003 I was involved with making sure that some of Apache Software Foundation's projects like Apache Ant run well on the then current version of the Kaffe.org virtual machine. That started off the merge of Kaffe and GNU Classpath projects and resulted in some first contacts between Kaffe, GNU Classpath and Apache developers. Kaffe.org started to gradually switch to GNU Classpath for its class libraries, driven by the needs of the users to run some of the excellent Apache software on a fully free stack.
Later in 2004, Mark Wielaard from GNU Classpath and me started looking at ways to improve the quality of GNU Classpath and Kaffe through automatic regression testing with popular free software written in Java. That immediately led us to the Apache Gump project, a continuous integration project that allows bugs preventing popular software from running to be noticed and caught as they happen, before they slip into releases. With the generous help of Leo Simons and Stefano Mazzochi, both Apache developers, we managed to set up Apache Gump with Kaffe and to set up a regression testing environment on top of it.
Going from that collaboration effort, strong ties to other Apache developers were created, most notably to Geir Magnusson Jr. from Apache Geronimo, and Davanum Srinivas from the Apache Axis project. Tom Tromey from Free Software Foundation's gcj project, Bruno Souza from SouJava, Sun's head of the Java Community Process Onno Kluyt, Geir, Mark and me met at the Red Hat Free Runtimes summit in Boston in late 2004, to discuss how to make a free software implementation of Java a reality.
While Sun had no interest in opening up their own implementation, Onno assured us that Sun Microsystems has removed the legal obstacles that existed before, which made it impossible for a free software implementation to be certified as compatible with the proprietary runtimes. Geir has worked together with Onno before to make sure that Apache's Geronimo, a free software implementation of J2EE, could happen, so he was interested in seeing a certified free software J2SE implementation happen as well, and Bruno has a lot of experience with the JCP.
In spring 2005, Geir, Bruno and me met again at the CafeBrazil conference. We discussed how to build a modular Java runtime and class libraries, similar to the concepts embodied in Apache Geronimo.
One idea was to have well-defined interfaces for parts of the VM and the class libraries where other modules can be plugged in transparently, so companies and independent developers can work together on some parts, and compete on others. The concept of "collaborative competition" has worked great for GNU Classpath, which now covers about 90% of 1.5 APIs, and is used by more than two dozen runtimes which both compete and collaborate on runtime components and the class library.
Given Apache Software Foundation's successful dealing with the JCP and Sun Microsystems in the past, the possibility of such a project being attractive to both independent developers and companies developing proprietary Java runtimes, and ASF's good reputation among Java developers, the ASF's incubator made for a good, prospective home.
After further discussion within Apache, the Apache Harmony project was proposed for incubation, accepted, and we started to work on the legal framework for contributions, merging in first large contributions from Archie Cobbs, IBM and Intel.
LinuxPlanet: Why do you think it's important to have an open source Java implementation?
Topic: After ten years, Java has become one of the most popular programming languages. There is a wealth of free software written in the Java programming language. We've now got several full free software J2EE stacks that run on top of free software support libraries, and on free software operating systems. There is only one remaining proprietary wedge in those stacks, and that's the Java implementation. I believe that one should not be forced to use proprietary software in order to use and share free software with other people.
Unfortunately, up to a few years ago, before the GNU Classpath project led by Mark Wielaard started really taking off, most of that software would require a proprietary Java implementation to run. Having free software that's so intimately tied to proprietary code made the free software written in Java less useful to users and developers than it could have been. For example, on those platforms where no company felt a business need to pay for a port of a proprietary implementation, no software written in Java could run. That included GNU/Linux, when the Kaffe project was founded in 1996.
Today, the free runtimes in the GNU Classpath runtime family are increasingly capable of running the latest free software written in Java, be it Eclipse, Azureus, or JOnAS. We're working together with distributors to make sure that the free software written in Java can be packaged, i.e., is building and working, with the free runtimes. Distributions like Ubuntu, Fedora, Debian, and others are shipping Eclipse and OpenOffice.org working on top of gcj and GNU Classpath today, which translates to millions of lines of code no longer forcing proprietary virtual machines down the throats of free software users and developers.
In addition, the free software runtimes around GNU Classpath are leading to some innovations in the Java space: IKVM allows Java code to run unmodified on top of .NET, JCVM, and gcj allow Java bytecode to be pre-translated ahead of time into fast native code, while projects like JNode are working on making the idea of a native Java operating system come true.
LinuxPlanet: What is the current status of Harmony within the Apache Software Foundation?
Topic: The Apache Harmony project has received several generous contributions. Archie Cobbs and Dan Lyddick have both contributed runtime engines, and IBM and Intel have contributed class library source code. Currently Archie and other Apache Harmony developers are working on publishing a first snapshot of the work that went in over the past nine months.
LinuxPlanet: If Sun releases Java as open source, or allows distribution on Linux, how would that affect Harmony's future?
Topic: It would be nice if Sun one day suddendly decided to release the source code for their J2SE implementation under an OSI-certified open source software license. I think Harmony, just like other free runtimes projects, would take a sharp look at the code and decide what they could reuse. I'd hope that Sun would work with the Apache Harmony project and other projects if they decided to go the open route.
Unfortunately, for a lot of business reasons at Sun, I don't see it happening in the near term future, although I know that it's a somewhat popular speculation.
I believe that Sun has missed that boat a few years ago, when a lot of people finally decided that they had enough of waiting for them to do the right thing and join us, and started routing around the problem, by working hard to make sure that the best implementation of the platform in the future will be free software.
A different proprietary license for Sun's proprietary software would not change anything. Developers and users increasingly do not want to spend their time and energy dealing with the bizarre whims of proprietary software publishers, if the free software alternatives work equally well or even better. I'd expect the free software runtimes in the GNU Classpath family, like Kaffe, gcj or Cacao to become seamless drop-in replacements for proprietary implementations in the next three years, removing the need for people to bother with the proprietary implementations when they want to use free software.
LinuxPlanet: What is the relationship between IBM and Harmony?
Topic: IBM is the employer of one full-time developer on Apache Harmony. They have contributed the implementation for a part of the core class library.
LinuxPlanet: Which version of Java are you targeting?
Topic: Apache Harmony is targeting J2SE 1.5.
LinuxPlanet: What can we expect in the future from Harmony?
Topic: I would expect Apache Harmony to spend this year in a reasearch and integration phase, where different components from different sources are still being made to fit well together. I'd love to see Apache Harmony run Eclipse next year, and I assume the project will apply for a TCK scholarship once it has reached such a milestone, to be able to run the compatibility test suites and keep improving the compliance with the specifications.
I would expect Apache Harmony to become useful in the next three to five years, depending on how many companies it can attract to contribute components to it. Since Apache Harmony is deliberately not using GNU Classpath, it will have to write all the class libraries. As that took GNU Classpath around 10 years, I'd expect Harmony to at best compress that to 5 years, assuming everything works out optimally.
Apache Harmony has already succeeded in one major thing: making free software Java runtimes something that most Java developers are no longer afraid of.
LinuxPlanet: Thanks very much for speaking with us about the Harmony project.
As an open source strategy consultant, Maria Winslow assists clients in understanding the technical and budgetary impact open source software will have on their computing environments. Her current book, The Practical Manager's Guide to Open Source [ http://windows-linux.com/practicalOpenSource ], guides IT directors and system administrators through the process of finding practical uses for open source that will integrate seamlessly into existing infrastructures, as well as understanding the costs and savings.
Copyright 2006