Thursday, October 23, 2008

Statistics for Developers

I have seen a lot of software developers not keeping up with whats happening around the world, unaware of the deployment landscape thus using development methodologies which will in the end make their software unusable by the end user. For example, I still meet a lot of web developers who test their websites only on the default IE installed, do not care about mobile browser display resolutions.

I came across some very good statistics websites which I want to share with the rest of the developer community. These statistics can also be of use to clients who need to get software developed but don't know what they should be asking for in terms of technical requirements.

  • Statistics for popular programming languages being used today. Look here and here. Java and C seem to be very popular but you need to keep in mind that these stats do not take into account the type of software being developed. For example you would not use C to make a website. But if you were to create a fast, native application for a mobile platform like Symbian or iPhone, you will have to use C or C++.

  • The most common browsers being used today can be seen here. Firefox has a huge user base. Safari and Chrome are also picking up.

  • Display resolutions statistics can be seen here. 1024x768 still rules but 38% of screens now use a much higher resolution. This list shows that some details of what kind of high resolutions are in use today.

  • Operating System statistics can be seen here. Some more OS stats can be seen here. Windows XP of course rules the desktop. But I am surprised to see that the Mac has a significant share of 5% to 8%. Just goes on to show that developers should spend some time testing their web applications on Safari as well. It also tells desktop application developers that they should invest time in learning cross-platform development technologies like Java, C++ or C.

  • I could not find a good statistics page showing whats going on in the Mobile Browser world at the moment. Its no secret that Opera Mini has a good market share. Webkit based browsers come built-in on most Nokia phones. iPhone's Safari browser is also Webkit based. I read that Blackberry's new mobiles will also use a Webkit based browser. If you want to target the mobile internet users' market, you should test your website using a Webkit based browser like Safari and at the same time use available emulators from Nokia, Apple etc. as the mobile versions have a cut down version of Javascript and CSS.

Thursday, October 16, 2008

Want to learn AJAX?

Just found a really awesome post "50 Excellent AJAX Tutorials". It covers AJAX examples for Pure Javascript, PHP, Java, ASP.NET etc. I need to use AJAX on my next upcoming assignment. Thought I would make note of this link.

For those who do not know what AJAX is, to the layman AJAX allows websites to look and feel like traditional software. Take Facebook for example, the site uses AJAX heavily. All those popups, dialog boxes, chat, photo upload, drag and drop etc. are done using AJAX.

A Petabyte sized database

Came across a very good article today about the Greenplum Database. Its an open source database which supports databases as big as a Petabyte or more (thats 1024 terabytes). All for free.

Who needs something like this? Its currently being geared towards data warehouses and Business Intelligence (BI) solutions. I might use it someday for the implementation of a BI solution as those database tend to get huge. For those unaware of what a BI solution does, suppose you have a company with multiple applications being used each with its own database, no integration. Now you want to make some analysis or generate some reports which require data to be read from these different databases, a BI solution can help you bring together all the data from each database, co-relate them, and then let you generate your report.

A BI solution actually ends up creating a database of its own which tends to get bigger as you try to integrate more and more databases together. Greenplum can help your BI solution save this newly acquired data.

A good open source BI solution is from Pentaho.

Inversion of Control (IoC) and Dependency Injection (DI) paradigms

Came across this very good explanation of Inversion of Control (IoC) and Dependency Injection (DI) paradigms. Thought I would make a note of it:
(click here for the complete article on Java Dev Journal)

The analogy people most often make when talking about IoC is called the Hollywood principle: "Don't call me, I'll call you." What this means is that you don't call the framework code, but the framework calls certain methods on your components. This isn't something new, for instance, when you look at the servlet interface, you can see that you must implement the init and destroy methods. These methods are called from the servlet container on startup and shutdown of your servlet. This concept is also used in Spring, among other things, for specifying which methods to call on construction and destruction of your POJO.

Besides IoC, another important concept to understand is Dependency Injection (DI). This term was coined by Martin Fowler and describes a pattern of how to perform wiring between beans. This means that any dependencies your POJO might have are injected into your component, instead of you having to retrieve them. In J2EE (at least until 1.5) when you required a resource (a data source, another bean, etc.) you had to use JNDI to pull that resource in. With DI you don't have to do that anymore. With DI your container will make sure you have the dependency pushed into your POJO using getters and setters. In the new J2EE specs much of the same concepts are used.

Thursday, October 9, 2008

The problems with Eclipse and why Netbeans will win in the long run

In the world of free (and open source) Java IDEs only 2 names come to mind, Eclipse and Netbeans. Eclipse was open sourced by IBM back in 2002 and spread like wild fire throughout the Java developer community. Thousands of plugins have been created for it and applications created using it as a base. Netbeans on the other hand is still relatively new and has a very small number of plugins compared to Eclipse.

But even with the thousands of plugins available, Eclipse has always been a very difficult environment to set up. A lot of the plugins have long been deserted by their developers and given the way Eclipse is designed, the old plugins do not work on the new versions of Eclipse. In the past I would find a plugin that I really thought could help me improve my coding. I would try to install it and then eclipse would attempt to install all dependencies for it only to fail. Most of the times the dependencies have not been updated for the Eclipse version I was using.

This is not to put down the commercial versions of Eclipse like MyEclipse or Websphere. They are very well built and work great out of the box.

The problem is that going through all the Java websites, journals, magazines, RSS feeds, blogs etc. the Java Developer community feels that they are not able to keep up with the speed with which Java is progressing. A couple of years ago when JSP and Servlets were new, we all spent time and learnt it only to find out that EJBs were the new thing. EJB was then replaced by Struts and Hibernate and all new jobs required that the developer should know them. Now there is a lot of noise about Spring and JSF. (I think I have gone off on a tangent here but I will end this trail by saying that the Java folk should upgrade current in-use frameworks rather than creating something new every 2 years; Its driving us developers crazy).

Coming back to my Eclipse plugins problem. So there is a hell of a lot that we need to learn and fast. Paying money for something I am not sure I will make any money out of is not what Developers normally do. We look for the freeware or the open source stuff. Eclipse has really depressed developers from using open source plugins.

I came across the EasyEclipse distro that has multiple bundles based on Eclipse available for free download for Web Dev, Desktop Dev etc. It does take out the headache of installing plugins yourself.

Yoxos is also a good service but to use it you will need to be familiar with the plugins you need to perform your task.

But if you want to learn to develop like a real PRO using the Eclipse platform, your best bet is to go for MyEclipse. At $30 this is the cheapest you can go.

Coming back to Netbeans, its good right out of the box and has awesome editors and does most of what you actually need to do in the real world. But when that new framework comes out which you really need to use, don't expect a plugin for Netbeans to be ready anytime soon. But hey things are changing.

For now, I plan to create my next app using Netbeans as I need a good GUI designer, Hibernate support, some database tools and UML designer. And all these come built right into Netbeans by default. I do wish there was some support for GCJ but not found that yet.

Sunday, October 5, 2008

PostGIS, Geoserver and OpenLayers for a complete GIS solution

Open source GIS solutions have come a long way in the last couple of years. It is no secret that Google Earth put GIS into the hands of millions and created a huge market for GIS users. Now that people are familiar with GIS systems and are willing to use a GIS, what do you really need to make a GIS system.

What you need is a GIS database with all your geotagged information in it. The data is then served through a GIS server to a GIS client. If you wish to target web clients, you can create your own complete GIS solution using PostGIS as the GIS database, Geoserver as the GIS server and OpenLayers as an interactive web-based client.