Archive for the ‘Opinion’ Category

The Java jungle: application servers

Wednesday, September 5th, 2007

As promised in this previous post, I will start this short serie by the JavaEE application servers jungle. As a side-effect I won’t consider Tomcat as it is not a full-stack application server. Also, I will only consider the opensource JavaEE servers.

JBoss

JBoss is an obvious option when it comes to JavaEE application servers. In fact, it delivers very well. I found the JBoss application server to be very easy to use. The documentation is good. You quickly forget that you are running it once your favorite IDE has been set-up. Also, the startup time is pretty fast (in fact, JBoss is the fastest that I have tested).

Of course JBoss is not perfect. There is not proper web administration console. Adding new resources (e.g., a new JDBC datasource pool) needs to be done by hand. This involves editing a few XML files and getting used to the files locations. There is nothing complicated in this though: it is just a matter of reading a bit of documentation and copying/editing sample files. This is yet not the simplest for teaching purposes. Apart from that, I like this application server a lot, and I encourage you to check out their impressive suite of middleware solutions.

JOnAS

I have not tested it as the stable releases are only JavaEE 1.4 certified.

Apache Geronimo

At first sight, I thought that Apache Geronimo would be roughly a JBoss clone. I was so wrong!

Geronimo is a pleasure to work with. The IDE support is very good (Eclipse, IntelliJ IDEA). It comes with a very good documentation. Last but not least, it has the best web admin console I have seen. You can do pretty much anything from there. For example, you can add JDBC datasource pools with a very intuitive wizard and Geronimo will download the drivers for you… or provide you with a link when some legal restrictions apply. You can also opt for Tomcat or Jetty as your servlets container which is very nice (to me, Jetty is superior by far to Tomcat…).

I was very impressed with Geronimo, yet I won’t use if for teaching purposes. The startup is a bit slow: I suspect that the GBeans framework (IoC) flexibility price is some CPU time. But my main complain is related to OpenEJB, the EJB container that is used by Geronimo. For some (biiiip)king reason, I could never manage to retrieve a remote session bean through JNDI from a standalone Java application… The lookup would always fail and I have really no idea why… This was never a problem with both JBoss and Glassfish (using the same application of course).

Glassfish

This is my choice :-)

Glassfish is the reference JavaEE implementation and it is pretty slick. The documentation is excellent as well as the IDE support (although IntelliJ IDEA 7 run console always gets disconnected from the server, which is a bit annoying). The administration console is very good, yet a bit less powerful than the one of Geronimo. The startup time is ok.

I also enjoy the fact that Glassfish supports multiple independent domains (i.e., domains are like Oracle instances). This is a must-have feature for labs as pair of students can have their own domains instead of having to reuse a (possibly broken!) one that was left from a previous lab session. The command-line asadmin tool is just great and it is very easy to manage instances, deploy applications, backup or restore domains and so on. The future Glassfish v3 is probably going to be highly attractive as it will support some nice features such as the direct deployment of RoR applications using JRuby.

Verdict

Glassfish wins by a narrow margin over Geronimo (stupid OpenEJB!). I won’t use JBoss for my teaching, not because of flaws but mostly because it lacks a proper administration console. Overall, Glassfish provides the most straightforward application server experience. It also looks to have a very bright future with the upcoming version 3 ;-)

Update: I have nearly launched a troll :-)

CDG

Friday, August 31st, 2007

Bonne nouvelle, je ne suis pas le seul à penser que l’aéroport Charles de Gaulle est une mauvaise vitrine pour notre pays. Cet aéroport n’est pas fonctionnel, il est profondémment sale et en plus l’accueil des passagers par les autorités est infecte (ni bonjour, ni sourire, ni merde). Pour avoir fait quelques aéroports internationaux (Sydney, Hong-Kong, Londres, Amsterdam, Singapore, Bangkok), je pense pouvoir affirmer combien notre plus gros aéroport est ignoble (quoique … Londres Heathrow n’est pas franchement mieux …).

Extraits choisis (j’ai mis en gras ce qui rejoint mon expérience personnelle) :

Lors de l’arrivée à San Francisco, les couloirs sont larges, propres, bien tenus. Les toilettes sont facilement trouvables, propres et nettoyées. Il y a du papier. PQ et papier pour les mains. Il y a suffisemment d’officiers d’immigration (un peu leur police des frontières à eux) pour accueillir simultanément trois 747. Il y a trois files avec plusieurs guichets chacune. Une pour les citoyens US et résidents. Une pour les visiteurs non américains. Une pour les immigrants. C’est bien fait, bien organisé, la salle est LARGE. Les bagages arrivent vite. La salle de contrôle de douane est grande, sérieuse. On vous contrôle sans vous prendre pour un connard ni vous regarder comme une merde.

Arrivée au dit-contrôle par des couloirs tout petits et sans toilettes. DEUX officiers de la PAF en tout. Un monde fou, un avion de Russes vient d’atterrir.

Douanier patibulaire voire grossier.

Je crois que mon meilleur souvenir de CDG restera quand même mon dernier départ pour Sydney, retardé faute à un bagage à faire exploser. Le CRS qui était dans la salle d’embarquement nous a parlé comme à des bestiaux (en même temps il est CRS, donc il a un QI de moineau tombé du nid). A un moment j’ai “osé” le regarder et il a mis sa main sur son flingue, prêt à dégainer … :-)

Some things Mozilla could have done better

Thursday, August 2nd, 2007

First of all, don’t get me wrong: Mozilla has been doing a fantastic job in the past few years. They managed to push an open source project (Firefox) to the masses in proportions like no other before. Yet, I personaly believe that they could have done much better on the following points.

  1. Bet on XulRunner: their framework is solid and mature. It probably requires a bit of syntactic sugar in some areas like XPCOM, but as a whole it is a very good one. We have seen some nice spin-offs recently such as SongBird and Miro. Yet, the Mozilla Foundation is reluctant to market XulRunner. The result is that the Mozilla platform is still a niche and few developers have the knowledge to build more than Firefox extensions. With the rise of RIA platforms such as Apollo, JavaFX or Silver, I am very pesimistic on the chances for Mozilla here… What a pitty, their platform had so much potential!
  2. Avoid the bloat in Gecko and Firefox: the facts are here, performance-wise things could get much better. Especially, the way Gecko handles memory is clearly not efficient as it leaks quite a bunch of memory. It also looks like Gecko is a complex piece of code. The recent rise of WebKit should be a warning: it does not have to be that complex! I predict that we will see an increasing range of browsers, applications and devices that use WebKit and not Gecko. Also, Opera has been much lighter for many years, still having lots of nice features…
  3. Invest more on Thunderbird: the issue is being much debated these days, so I won’t jump into it. Although Thunderbird fits my needs very well, more resources (including marketing) have to go into it.
  4. Market the Mozilla Public License: this license is simply excellent as a middle-ground between liberal (BSD, MIT, …) and restrictive licenses (GPL). Many people and organizations fit more into this type of license, yet Mozilla is apparently not going to push it anytime soon dispite the clear potential benefits. I suggest that they make a new version of the MPL that would be less Mozilla-specific so that other projects could reuse it instead of making derivatives (e.g., the CDDL from Sun). That is exactly what Apache did with the version 2 of their license, and many ASL-licensed projects have fostered since then.
  5. Integrate better their applications on MacOS X: I am aware that work is under way here, but having form buttons in web pages that look like on Windows 95, or having Firefox not picking up the system proxy settings is not nice (Camino does pick it up right BTW).