LWN.net Logo

Coming soon: a free Java

Sun Microsystems took advantage of LinuxWorld to announce that, at long last, it was serious about releasing much of its Java system under an open source license. The upcoming releases - which could happen by the end of the year - will include both the Java Standard Edition and Java Micro Edition products. The Hotspot VM and the Java Development Kit are to be part of this release. For many Java developers, this is the moment they have been waiting for. Of course, there are a few remaining questions.

For years, Sun has resisted calls to release Java. The company's primary reason for keeping Java proprietary was that it was necessary to keep Java implementations compatible. A truly free Java would compromise the "write once, run everywhere" promise frequently made (if less frequently kept) by Sun. So, one might well ask what has changed. Here's the story from Sun:

We now think the benefits of accelerating innovation, opening new markets and opportunities, and fostering creativity that the open source model brings now outweigh the risks to compatibility. These risks are real, but at Sun, we believe that the wisdom of the community has evolved to where the market and developer community itself will act to demand compatibility as a bedrock feature of any implementations based on Java technology.

So, in other words, we are now smart enough to be entrusted with a free Java. Better late than never.

The usual post-announcement routine will have to be endured before a free Java is a reality. A thorough review of the code must be done so that Sun's lawyers can convince themselves that Sun has the right to release it all, and any encumbrances must be dealt with. Some sort of governance model must be chosen: who will decide what changes make it into mainline Java? Sun will want to retain some control here, but an overly tight-fisted approach could encourage a fork of the code and a potential loss of the compatibility that Sun values so highly.

Then, there is the issue of what license is to be used for the Java release. One might expect Sun to reach for the CDDL first, and that might be just how it plays out. But Sun might just want to consider how the newly-licensed Java would play with existing free projects. GNU Classpath is licensed under the GPL, so mixing of Java and Classpath code can only happen if Java carries a GPL-compatible license. On the other hand, the Apache Harmony project, which has made great strides toward an independent and free Java SE implementation, is using the Apache V2 license, which is not compatible with the GPL. This license difference has helped to keep Classpath and Harmony separate until now, and Java may have to choose a side (or neither).

One intriguing possibility is that Java could be released under GPLv3 (as soon as that license is real); version 3 of the GPL is intended to be compatible with the Apache license.

All of this depends on whether Sun places any value on license compatibility with the other projects or not - and how that value compares to Sun's other goals. Sun will have to work through a lot of issues before it can come to a real answer to these questions. But it does appear that the company has committed itself to releasing Java under a free license, and that can only be a good thing.


(Log in to post comments)

GPL libraries in a JVM ....

Posted Aug 17, 2006 1:50 UTC (Thu) by yodermk (subscriber, #3803) [Link]

Just thinking out loud here, but would running Classpath under a non-GPL JVM *really* violate the GPL? After all, the code is not really being linked together. Since there are various JVMs and various classpath implementations, one could reasonably argue that they are not intrinsically linked together.

Maybe it doesn't even matter, assuming Sun's class libraries are open sourced as well.

GPL libraries in a JVM ....

Posted Aug 17, 2006 2:03 UTC (Thu) by scruffie (guest, #5704) [Link]

The value of open-sourcing Sun's Java is not in the JVM (there's several projects that have good ones), but in the Java class libraries. The concern would be how those are compatible with the GPL.

GPL libraries in a JVM ....

Posted Aug 17, 2006 4:39 UTC (Thu) by jamesh (guest, #1159) [Link]

The GNU Classpath is licensed under GPL + exception. So running GNU classpath against a non-GPL JVM is not a problem.

The issue here is that Sun's JVM also comes with a class library implementing the same interfaces as GNU Classpath. So license compatibility only really becomes an issue if you want to try and merge the best features of both class libraries together since the exception would not apply.

GPL libraries in a JVM ....

Posted Aug 17, 2006 8:40 UTC (Thu) by hppnq (guest, #14462) [Link]

Interesting point. It's a bit strange though to see this casual mixing of the terms "running", "linking" and "distributing" as if there's no difference. This is all explained in the first paragraphs of the GPLv2.

I thought I'd mention that, since the GPL, and therefore the exception made for GNU Classpath, addresses exactly this point. ;-)

You could *run* (and therefore possibly link) GNU Classpath with any JVM with or without the exception, for instance. You just might not be allowed to distribute it.

Better late than never

Posted Aug 17, 2006 8:28 UTC (Thu) by dion (subscriber, #2764) [Link]

I've always wondered why Sun refused to opensource java, I mean if time has shown one thing then it's that opensourcing something will go a long way towards ensuring that people will trust it enough to use it.

Just look at KDE, before Qt was officially Stallman-compliant a lot of people didn't trust it enough to use it and some even started a competing project.

The same thing happened with Java, some people didn't trust it and they went ahead and wrote their own incompatible replacement which they could have more control over.

Now, given that Gnome havn't given up although their reason for starting is gone, I think it's safe to say that .Net (and mono) will not go away either.

Sun is simply coat-tailing

Posted Aug 17, 2006 11:16 UTC (Thu) by fredrik (subscriber, #232) [Link]

My interpretation of Sun's real motivation not to open source java until now is the historic scepticism agains anything open source. Not from any technical perspecive, but from managers in big business organisations.

Move five or so years back in time, and anything labeled open source was still strugling with a credibility issue - again not for technical reasons, but for marketing and business aspects - among business management. At that thime there almost wasn't a single issue of lwn without the word FUD in it, remember? So, to get all those conserverative proprietary software development organisations on the Java train Sun argued that Java was credible because it was controlled by a standards friendly but strict managed and business aware corporation. Actually this argument has been made up until this spring if I remember correctly.

Anyway, over the last couple of years, this general open source scepticism has mostly vanished and instead the open source label provides credibility even among some of those previously so sceptical pointy haired bosses. Big blue, intel, motorola, nokia - you name it and it sure has a open source strategy, maybe not a public one, but it's there...

So, if you like, you could simply call Sun opportunists. When the wind blew against open source, they assured their customers that Sun would never allow Java to be "spoiled" that way. Now when the wind has turned, so has Sun's argument.

Admittedly, I have no hard proof for the above argument. Besides, Java is still a tool I use with pleasure every day at work, and even if I am right and Sun's motivations to some extent are murky, I still applaud the end result.

Fredrik Jonson

Sun is simply coat-tailing

Posted Aug 17, 2006 15:44 UTC (Thu) by tnoo (subscriber, #20427) [Link]

> My interpretation of Sun's real motivation not to open source java
> until now is the historic scepticism agains anything open source. Not
> from any technical perspecive, but from managers in big business
> organisations.

Remember who bought Staroffice and released it under the LGPL?
(http://about.openoffice.org/index.html)

So maybe not releasing Java was intended to protect Sun's crown jewels?

Sun is simply coat-tailing

Posted Aug 17, 2006 20:12 UTC (Thu) by fredrik (subscriber, #232) [Link]

I'm not claiming that it was Sun that was skeptical against open source. Rather I'm arguing that Sun's problem was that they had to convince the more conservative parts of the business software organisations that Java would continue to be a serious endevour, credible enough to be a widely accepted programming environment. As opposed to some kind of akvard social experiment - which is how I believe top management in many business software organisations still perceived anything associated with open source only a couple of years ago.

Of course a lot has happened since then. Sun's experience with Openoffice.org could very well be one factor. The serious interest large business organisations has shown the Apache Harmony project could be another.

Basically, I think it was a matter of being confident that no big player was going to jump ship when Sun changed course.

Fredrik Jonson

Sun is simply coat-tailing

Posted Aug 18, 2006 14:38 UTC (Fri) by job (guest, #670) [Link]

Yeah, well, it's not the first time Sun suffers from split personality.

Better late than never

Posted Aug 17, 2006 11:21 UTC (Thu) by NRArnot (subscriber, #3033) [Link]

I've always been very clear, and somewhat sympathetic. Sun wanted to make sure that no-one (OK, MS) was able to hijack the language: embrace, extend (preferably with patent-encumbered closed stuff) and extinguish. MS did try. Sun went to court, and won.

They now think that Java is sufficiently well-established that programmers would avoid anything that attempted to introduce incompatibilities. I hope they are right.

Elsewhere, look at what MS has done with Kerberos. IMO they also tried to hijack HTML, but there they arrived too late to do anything much worse than to make IE the non-standard and bugridden mess you know and hate. Even so, there are still some sites out thre that won't work right if you don't use IE to access them. Less each year, probably thanks to Firefox.

Better late than never

Posted Aug 17, 2006 14:12 UTC (Thu) by vmole (guest, #111) [Link]

It would be fair to point out that the Netscape browser of the time *also* implemented a non-standard, buggy version of HTML.

Better late than never

Posted Aug 17, 2006 15:36 UTC (Thu) by cventers (subscriber, #31465) [Link]

...which is why they shouldn't be wasting their energy on crap like
"CDDL" and instead should have just adopted a license like the GPL. The
GPL strongly defends against the triple E's.

so they "won", did they?

Posted Aug 17, 2006 17:03 UTC (Thu) by JoeBuck (subscriber, #2330) [Link]

Microsoft responded by creating an alternative Java called C# and an alternative byte-coded virtual machine framework called .NET, rendering Sun's control of Java meaningless, and there's a free implementation called Mono that runs on Linux and Solaris. Now Sun has to make Java free to stop Mono from taking over Linux/Unix/BSD land (at least, taking over that portion of *nix land that finds the Java model attractive).

Microsoft hijacking HTML

Posted Aug 17, 2006 23:35 UTC (Thu) by giraffedata (subscriber, #1954) [Link]

Microsoft failed to hijack HTML? That's the first I've heard of that opinion. In my view, IE is the standard. It's the only standard worth recognizing for a browser: the standard to which websites are designed.

I used to use IE a lot (not so much since I installed Firefox on my Windows system and found it 99% IE-compatible), and I didn't hate it for being bugridden; it always seems to work for me. The only thing I hate about IE is its lack of function.

Microsoft hijacking HTML

Posted Aug 24, 2006 13:19 UTC (Thu) by csamuel (✭ supporter ✭, #2624) [Link]

I thought it was very successful in its main area of functionality, that
of introducing viruses, spyware, adware, trojans and various other bits
of badness to those unfortunate enough to have to use Windows.. ?

interview

Posted Aug 17, 2006 9:35 UTC (Thu) by markstradling (guest, #5814) [Link]

Silicon Valley Sleuth has a video interview with Rich Green from Sun here: http://www.siliconvalleysleuth.com/2006/08/open_source_ja....

He doesn't seem particular impressed with the idea of using the GPL.

GCJ and Kaffe perspectives

Posted Aug 17, 2006 12:39 UTC (Thu) by mjw (subscriber, #16740) [Link]

There are some encouraging words from Tom Tromey (GCJ) and Dalibor Topic (Kaffe).

Lets hope Sun listens. As they say, this could be awesome, if played right.

Coming soon: a free Java

Posted Aug 17, 2006 13:57 UTC (Thu) by davecb (subscriber, #1574) [Link]

I seriously doubt that issues with the Open Source / Free Software community were ever on Sun's radar.

Sun's concern was with Microsoft repeating their previous attempt to "embrace and extend" Java. You may recollect MS had to pay Sun millions of dollars for breach of their contract to use the name "java" for a langage that actually wasn't java.

Since MS wrote C#, which is just a MS-specific java by a different name, Sun can no longer protect themselves by restricting the name, and so can loosen the restrictions on our community.

--dave

Coming soon: a free Java

Posted Aug 17, 2006 14:41 UTC (Thu) by tjc (subscriber, #137) [Link]

I seriously doubt that issues with the Open Source / Free Software community were ever on Sun's radar.
Or vise versa. It's hard to get a group of Phython and Ruby progammers excited about Java. I suppose that some people who are constrained to use Java in a corporate setting will find this to be exciting news.

And?

Posted Aug 17, 2006 20:44 UTC (Thu) by ncm (subscriber, #165) [Link]

Does it mean anything to "open-source Java", or even to "free Java"? Java is a language, not a program. Sun has programs to compile Java to bytecodes, bytecode interpreters, libraries typical Java programs rely on, and test suites. The language definition itself might be released to an independent body responsible to the community, and the standard library definitions similarly. If they Free any of these things, those might be worth reporting, but none, alone, would constitute freeing Java itself.

Here's a prediction: the moment Sun completes freeing Java is the point at which it has become entirely irrelevant to their strategic plans. That will be the point at which anybody *still* coding Java should finally, belatedly, consider acquiring career skills not tied to the whims of a single corporation.

Doing the right thing

Posted Aug 17, 2006 23:31 UTC (Thu) by bojan (subscriber, #14302) [Link]

Sun should do here the exact opposite to what they did with OpenSolaris, where they made sure OpenSolaris community never exchanges any code with the Linux community. Instead, their number one priority should be making sure that *all current* free Java communities are better integrated with each other and can benefit from Sun's code drop. Of course, licensing of this code is going to be *crucial* to achieve this.

With embarrasing bugs like this:

http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4802695

Sun really do need the community to help. At present, the community has outdone Sun with gcjwebplugin, which can at least run *some* applets on 64-bit Linux machines. I know, it's not complete and all, but at least it *does run* for a limited number of cases, unlike Sun's implementation that does not even ship that code, after being asked repeatedly for over 3 1/2 years. This is just an example, of course.

So, Sun folks reading LWN (and I've been told by other LWN readers previously that they are visiting here regularly), please ask your management to do the right thing. Make sure Java becomes as ubiquitous as Perl on all Linux/Unix machines, by letting code be interchanged freely between your implementation and the others. Then we're going to be getting somewhere.

Copyright © 2006, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds