maandag 26 januari 2009

Java and the Future

The release of Java SE 7 heats up a lot of discussion. This gave me reason to think more about what Java can do for me as a developer. Let me take one example. Java 7 will not contain closures. Well a lot is said about this topic, and I do not want to repeat this discussion. However, it did show me an aspect of Java, which I was not aware of. 

The thing is, Java is based on a lot of history by now. This also means a lot of design mistakes. There are many insights on how things could have been better. There are missing features in the language, like closures. There are also awkward standard libraries, which could be redesigned much better. This is not at all criticism towards the designers of Java, it is just that people learn as they go along the way. 

There is also the tendency in software development to combine imperative and functional programming styles and get the best of both worlds. 

I think that it is time to get a new start. Either break with history and let Java develop without the burden of the older releases, breaking backward compatibility, or get a new promissing language and start from scratch. 

The second alternative seems to get some body by the fact that SpringSource, the company behind the well known Spring framework, has bought company the Groovy and Grails framework. Groovy is a language that is compatible with Java, so all old code is still usable, but the language is better designed and more complete. 

Because one can retain the backward compatibility with older Java based systems, I think the second alternative is actually the better solution. Anyway, it will be difficult to make Java a more functional language. I think the coming years might get very interesting as languages like Groovy and Scala and may others get higher popularity. It will probably require higher skills from the developers, to master functional programming and imperative programming. At the other hand, we can safely stand on shoulders of the giants that explored a lot of territory for us.