Since Oracle took over Java from Sun in 2009 their management of the Java software suite and custodianship of the programming language has been met with mixed reactions. About half of Java users are generally supportive and the other half seem to be critical. Traditionally the language is extended via new “versions” of the JDK and today Oracle is planning the 8th version of the Java language.
Java 8 is scheduled for release in the summer of 2013 and will include the final components of some of the features that were planned for Java 7 – namely their Rich Internet Application package “JavaFX” and “Project Coin” – and some new features such as language support for Collections and Lambda expressions.
Now it seems that Lambdas will be the interesting part. This feature is the only one of the two originally planned headline packages for Java 8 that is actually going ahead – the other being Project Jigsaw which is now planned for Java 9.
We’ll look at Lambdas in a moment, but so that you have a full overview of what we are talking about lets just look at Project Jigsaw quickly. This feature is planned to enable you to write “Modular applications” in JSE, which should make Java more scaleable and enable you to write Java applications onto small embedded devices like smart phones and tablets (I suppose to compete with Android, J2ME, Objective-C and the like). The reason for kicking this into the long grass is purportedly to ensure that version 8 is released as bug free as possible.
So on the face of it, it looks like Java 8 is going to be a bit of a damp squib. Ambitions have been scaled back and only one new feature is being released. What are they going to release that is going to be new?
Lambda expressions and PlayStation 3
Innovation in hardware has continued down the route of increasing performance by parallelizing computations across “several cores”, moving from a world of single core processors or a multi core world. Remember the fuss about Playstation 3? That was Sony’s move from a single core processor to a multi-core.
Today the corporate world of programming is starting to catch up on that technical lag and a demand has begun for a language that better utilises the performance potential of a multi-core environment.
Enter Lambda expressions and functional programming.
Lambda expressions, or anonymous functions, is a way of writing code that is functionally based. By adding Lambda expressions into the Java suite Oracle is looking to bring into their tent the functional features so far available on JVM with Scala and Clojure. Giving their clients a language platform that is more compatible than the existing JVM variants and utilises the increased performance of a multi-core environment.
Is this new?
Well it is for Oracle’s Java suite. Very new in fact. But in terms of programming, .Net adopted Lambda expressions 5 years ago in 2007 (as a feature of C# 4.0). F#, Lisp, Scala and Clojure already exist and are widely used. Oracle is actually playing catch up here, not breaking new territory.
Language vs platform
At this point it is useful to come back to the divide between the Java programming language and the Java software suite – interestingly Microsoft makes the distinction easier by calling the former C# and the latter .Net whereas with Java its just “Java”. Unlike Microsoft Java has a massive community building Open Source frameworks and features, adding a rich and sizeable driving force behind the language’s development. Oracle owns the software suite but not the language, and it’s from this Open Source space that much of the new functionality of Java has been developed. So Spring and Hibernate are both from the Open Source community, not Oracle. Since 2009 Oracle has “progressed” Java by adopting / absorbing these innovations, so EBJ3 is their version of Spring and JPA is their version of Hibernate.
So what is new with Java 8?
Developers already had access to functional features with Scala – an object oriented language with closures. And they can already write applications on embedded devices using android or J2ME or Objective-C (the point of Project Jigsaw).
Well the Lambdas is going to be very well received by Oracle’s big corporate clients. Small companies that use Java have probably already adopted a functional language if they wanted to exploit a multi-core infrastructure, the big players however are less likely to have done so because they are much more risk adverse and for them it makes sense to wait until you get an “official” version that is supported by Oracle.
But to everybody else, Oracle is spending a lot of time and effort standardising what already exits, instead of inventing new features they are consolidating the Java position.
I think the question is not,“Can Oracle keep the Java train on the tracks?” but “Where are those tracks leading?”
By absorbing the advances made by the open source community Oracle is taking Java down a track that will eventually look like this: Oracle don’t own the Java language, but they do provide support for it. By writing each JDK they also determine what features will be compatible with “their” software platform, and it doesn’t take a genius to see that before long they can exclude Open Source features that they now have a version of (JPA and EJB3 for example) and withdraw support for technologies they don’t own. Effectively dictating what is going to be compatible with their platform and what isn’t, finally asserting the ability to control the Java world they purchased in 2009.
Fine, that’s what corporations do – make money from stuff they own – but in doing so surely they are going to push out the Open Source community which is what defines Java from C# and that has for the last 3 years been the only driving force for innovation?
Is Oracle going to crash their own train?
Not quite. I suspect that they will continue to fudge things, potentially pushing out the little companies, continuing to lose support in the OS world but ultimately not withdrawing support for the legacy JDKs because too many big companies (such as the Investment Banks) rely upon OS technologies like Spring and out-dated JDKs like 1.5 and their business is too integral to the income Oracle makes on Java. And Lambdas in Java 8 will be popular with their big fee earners. So we will see increased the capitalisation from ownership… but not world domination.