Sunday, April 13, 2008

Competition is Good, even for Java

For about the last decade, a flame-war has existed in the Java camps:
  • Swing vs. SWT
  • Netbeans vs. Eclipse
  • Sun vs. IBM
You seldom read about the advantages of a diverse development ecosystem, and instead, the generalized perception is that competing Java libraries hurts the Java platform as a whole. I tend to take an opposite view; that the inter-Java component competition is a much needed and healthy aspect of the platform and will be the critical element for success in the future.

The following is mostly my own guess as to how things have gone down with the Java platform. I'm guessing that most of what I've written here is seemingly accurate, though undoubtedly there are some mistakes in the timeline and/or motivations of the interested parties. I believe this is close enough to the truth to be acceptable for the point I'm attempting to make.

From a likely naive read of Java history, it seems obvious to me that the competition between companies like IBM and Sun over the Java platform has strengthened the platform as a whole, created new options, more mature APIs, and has eventually lead to the opening of the Java source code by Sun in 2007.

For example, when IBM started to look at Java's AWT (Abstract Window Toolkit) graphic framework, improvements needed to be made to provide better fidelity with the native operating system underneath. AWT was basically judged as unacceptable by IBM for use in the development of its Visual Age IDE. AWT was clunky and lacked many features, and as such, IBM chose to develop its own windowing toolkit which did not rely on AWT and provided for better native OS integration. IBM came out with SWT (Standard Widget Toolkit) which, unlike AWT, had native renderings for the various graphic interface windowing components. SWT was fast and looked native.

Meanwhile, Sun pushed forward on the development of AWT by creating Swing, a light-weight layer sitting atop the AWT framework. With Swing, Java developers would have a very consistent API to developing moderately decent looking graphic user interfaces. Even with Swing though, IBM was not satisfied and was instead seeing great strides being made in its SWT platform, both in terms of functionality and performance. IBM stuck with SWT and Swing development slowed, mostly due to legitimate and fundamental criticisms over Swing (slow, kludgey, non-native rendering). IBM had picked the right horse to bet on, at least for the time being.

Today however, that perspective of the "right horse" is changing. A comparison is being made between the Eclipse and Netbeans IDEs (Integrated Development Environment) developed by IBM and Sun respectively. Netbeans, being based on Swing, has largely suffered from the original criticisms leveled against Swing, while Eclipse has been left rolling on highs as the king of Java development environments.

But recently, Netbeans (mostly because of the strong improvements to Swing) has made extrodinarily amazing gains in performance and functionality and is garnering attention from multiple technology critics, fairing well in comparison to Eclipse. Netbeans is now a viable competitor to Eclipse, possibly about even in developer mindshare. Eclipse vs. Netbeans is now the next Java holy war. Swing, once all but considered dead, is now extremely healthy and alive.

I have recently read a few forum postings and blog postings which say something to the effect that "Sun was right" to stick with Swing and that "IBM was wrong" to keep pushing on SWT. The comparison has primarily come from recent perceived performance problems in the latest versions of Eclipse, as well as the inability for Eclipse to run on all platforms as well as Netbeans. Swing has made significant improvements in the last two major Java versions; at this point, for most applications, it's as good as native applications.

In all this, what seems to be easily forgotten is that IBM was "right" to make the decisions that they did. At the time, AWT/Swing was just not viable. If Sun had been more cooperative with IBM, then perhaps SWT wouldn't exist. SWT has created good competition that Swing has been forced to mature quickly. And, fundamentally this is a good thing!

The competition between IBM and Sun has only pushed Java forward in a positive direction. Another example is the recent open source release of the Java framework. Previously, the Java source code was only available under a fairly restrictive license, but again due to pressure from other competitive sources (IBM, Redhat, Microsoft, Oracle), Sun has gotten all the parties to the table in order to open source Java in a GPL derivative license. The healthy Inter-platform Java competition has again benefited the Java ecosystem as a whole.

Ultimately, my hat goes off to the good folks at both IBM and Sun. I believe it's because of both their efforts (among many countless other organizations not even mentioned here) that Java is truly a fantastic environment to create a whole host of applications. I hope that the lesson learned is that free market values and the competitive spirit does indeed work to create better products. The gift of Java is a great example of this competitive and innovative spirit.

Tuesday, April 8, 2008

Python Wins

It's official... Python is now the official web application language of the future. For many many years, we've had an intense battle for the hearts of the multitudes of web application developers. While the battle is still being fought, and likely many on the battlefield will disagree, the winner is now decisively clear.

Recently, Google announced the creation of an "App Engine," which is a highly scalable web application framework. The App Engine allows developers to plug into Google's infrastructure to provide highly scalable and reliable hosting for the application environment.

Amazon should probably be considered the first mover in this field of usable and scalable developer infrastructure resources, with such services as EC2, S3, etc. Google too has had a strong role in offering APIs and other remote interfaces into their environment.

But, now it's game over. The writing is on the wall. Web hosting providers should know their time has come to an end.

As an extremely small web host and web application programmer, I've enjoyed a steady flow of income hosting websites and small web applications for various businesses. I've hosted on my own dedicated (leased) servers mostly out of necessity. It is much easier to provide custom services on my own platform than trying to use someone else's nickel-and-dime hosting provider. I install the tools I need, get the database running, essentially everything I need is available to do what I need to do quickly.

Awhile ago (a few years?), Google announced their "Google Apps" service (of which the App Engine will be a part), which is a broad set of useful services for businesses, including email hosting (through GMail), documents, calendars, etc. Google Apps allows the use of custom domains, so for example, my adamtaft.com email is routed through Google Apps / GMail. (Works great by the way, which is another future blog posting).

Included in Google Apps is a quite lame web page hosting service, called Google Pages. I checked out the service when it first arrived, and basically came to the realization that it was just a toy for the tweens, not really ready or equipped for a full service website or web application. It reminded me of other free hosting providers, like geocities or the like.

I knew it would happen though... I knew eventually Google would offer a total and complete web application environment such that would be useful under the Google Apps umbrella and provide the missing server side programming traditional of web hosting provides. The App Engine offers 500 MB of storage for free, and apparently 5 million page views per month (how that translates into actual bandwidth, I don't know). The data storage resides on Google's cloud (GFS / BigTable), so you can expect the same scalability and reliability as Google search has itself.

What does all this mean? It means the end is near and that Google will now begin to take a lion's share of web hosting away from small web hosting services. And, because of the fact that the App Engine supports Python (at least for now, likely other languages on the way), it makes a strong case towards knowing and developing future projects in the various Python environments. In fact, Google ships a version of Django (a Python based web application environment) with their App Engine SDK. (note, all python libraries are not available, but most of those which are useful for web application development are)

I've known for a long time I want to be out of the business of actually maintaining the hosting servers; it's a pain for a small guy like myself. So, from my point of view, this is fantastic news. Now I can concentrate on providing actual value added services to my clients (i.e. actual billable hours) instead of constantly needing to work on the maintenance of the infrastructure itself.

Ruby on Rails, Java, .NET, PHP, Perl... These are all great web application environments. I know quite a bit about a few of them (I'm obviously a Java fan boy). But clearly, I have neglected Python for too long now. The wake up call is here. I'm just glad I hear the alarm going off.