A Better Java

Imagine you’re Sun “the network is the computer” Microsystems. You’ve build your Java empire for quite a while without real comparable competition. And best of all: Microsoft has been more or less on your side (by launching J++ and including the fastest JVM in Windows, the Microsoft JVM). But then what happens? Microsoft wants to add proprietary, OS-dependent features into Java. That’s not going to happen! So you throw them out and disallow them to use a JVM at all. Ha! You don’t need Microsoft, you’re Sun Microsystems!

Guess what? Microsoft now launches its own Java-like project, called .NET. It has a JVM-like engine (called the CLR) and a Java-like language called C#. The bad thing is that the people from Microsoft could draw from years of experience with what did and what did not work in Java, C++ and other platforms, so they enter the market with a better product. C# has some nice new features, which indeed seem quite useful, and that developers seem to like. Also some new features, like generics, are planned for future releases.

What do you do?

First you have to check if people will switch to the competition. If not, you don’t have to do anything. Luckily, you find this excellent JDJ article entitled Java is Back!. The message appears to be positive, but there’s one worrying aspect. In the article the JDJ people have used an ingenious way to see which one’s more popular, Java or .NET. They did this using the website Googlefight which checks of two keywords which returns the most matches in Google. JDJ did this with Java and .NET and the results were surprising: .NET won! Oh no, what now?

Good business practice is to listen to customers. The customers by now are asking for the C# features. So what should you do? — You implement them in Java, only better! But wait, we have backwards compatibility to think about. If we implement generics, programmes written using them should also work on older JVM versions. That’s why you choose to implement them using a wipe-method that has been around as a third-party Java extention for years. It’s not nearly as nice as it could’ve been, but it’s something. But there are other features aswell: metadata, boxing, enhanced for-loop, loads of API changes and more. Wait, you can’t implement those without breaking backwards compatibilty! Hmm, alright, we’ll do them anyway, and therefore will break backwards compatibility. Life is all about compromises.

That didn’t work out as pretty as you would have planned. You ended up with a quite-sad implementation of generics that doesn’t break backwards compatibility, and a load of changes that do. So, technically you’re not going to be superiour. What options do you have left? Ehm, marketing. You haven’t done much on marketing yet. Now, what would be catchy? Oh oh oh! You know. Because the new Java version is so much better, you’re going to rename it, not to Java 2, because, confusingly, you already have that. Not Java 3, or Java 4. No, you’ll rename it to…

JAVA 5!

Oh wow, that would be so cool! But on the other hand, it’s also a bit confusing with all the old versioning stuff. OK, the short name will be Java 5, and the long version will be: version 1.5.0 of the Java 2 Platform Standard Edition 5.

And you know life will be great.