середа, 16 жовтня 2013 р.

1000 Responses to Java Is Not Dying

My editorial last week, "If Java is Dying, It Sure Looks Awfully Healthy"  hit a nerve in various developer communities. Between Reddit, Hacker News, and Slashdot, it received more than 1,000 comments. Curiously, very few commenters disputed my central argument; namely, that the common prejudice that Java is dying is not supported by the reality. Here, however, are the major points they did make:

Java is not dying, but it is becoming a legacy language. This was perhaps the most common theme. Legacy languages, in my experience, are characterized by two traits. First, their codebase increases only to the extent that is required by maintenance of existing code. That is, new projects in which any language can be employed rarely opt for the legacy language. The second feature is that some other language or languages are widely used for the type of software previously written in the legacy language. In this sense, COBOL fits the definition of legacy: Business apps today tend not to be written in COBOL, but in a myriad of other languages, notably, um, Java.
I don't buy this legacy argument because I see no real evidence that either criterion has been met. Android alone guarantees that many news projects are being written in Java. And in the enterprise, I see no language that has taken Java's place. The popularity of Spring suggests that Java is still very much a preferred language for enterprises. JavaScript both as a client-facing technology and in Node.js might eventually push Java out of a portion of the Web app space, in the same way Ruby on Rails did for smaller sites. In that narrow area, Java might become legacy, but it is too early to see the extent to which this will happen, as lots of Web frameworks in Java are actively used in new projects.
Java only appears to be dying because the cool kids prefer other languages. I agree this is true. Software development is living through a "golden age" of new language development. In the last 15 years, D, Erlang, Lua, Ruby, Scala, Groovy, Clojure, among others have all emerged (although some were created long before this period of growing popularity), while a whole crop of new languages are competing for attention: Go, Rust, CoffeeScript, R, and Haskell, to name a few. Never in the history of computing has there been such a wealth of language options with such a wide variety of features. Given that many university computer-science programs use Java as a teaching language, there is the perception that Java represents the status quo, while the new languages are the emerging items of true interest. I share this view. I like exploring new languages, but their presence says little about Java. As one Redditor observed, "I'm fairly new to the scene, having just gotten my degree this year, but Java and C#/.NET certainly are not 'dying.' I'm on my second job now, and have written Java for both."
Java on the desktop is dead. Here, too, I tend to agree. Java applets are almost entirely gone except in a few niches where they provide a special benefit. And even though JavaFX is a big upgrade from Swing, I don't think it will be enough for Java to reclaim a major role in client interfaces, especially not on the desktop. However, Java hasn't been a factor on the desktop for a long time, so its future absence from the space is not really an indication of its overall health.
The Oracle factor. It's true that Oracle is not a popular company among developers. Its handling of many of the assets it acquired from Sun, especially open-source projects, did not enhance its reputation with programmers. But for the period that Oracle has had Java under its wing, I believe it has done a better job in advancing the language than Sun did. I mentioned this in the original editorial. Moreover, I'm unconvinced that being a "good nurturer" of a language is a factor of overriding value. Consider JavaScript, whose renaissance needs no elaboration by me. It's a language that nearly everyone complains about — and it has not been revved in years. The lack of updates does not seem to limit its popularity, even though most developers would love to see more than a few of its limitations addressed.
And finally…several commenters agreed wholly with the editorial and thought it did not go far enough. They pointed specifically to the very high quality of tools in the Java ecosystem, especially IDEs; the vast array of libraries — many of which are available as open source; the remarkable portability of Java bytecode; and the wealth of documentation and resources available to developers. One might argue these are the benefits of long-time languages, but I can think of no other language — older or younger — that has all these features in such profusion.
— Andrew Binstock
Editor in Chief
Twitter: platypusguy