In the past I have worked with J2EE 1.4 and admittedly, it was terrible. A lot of plumbing code was required to make applications. Luckily, Spring and Hibernate came to the rescue: Spring for the general infrastructure parts (roughly session EJB replacement) and Hibernate for the persistence part (entity EJB replacement).
Meanwhile, Java EE 5 has been release which has solved a large number of problems and that came a long way in addressing developer productivity. Now, however with the new Java EE 6 standard (released 10th December 2009), things have improved even more.
In a series of blogs I intend to show why Java EE 6 with Contexts and Dependency Injection and JPA as important features should become the preferred tools for development. CDI is a dependency injection standard that is quite similar to Google Guice (although some might disagree) and is largely based on the experiences gained in the last years with dependency injection frameworks. Interestingly, CDI provides an API that allows integration of Java EE dependency injection (e.g. @PersistenceContext, @EJB, @Resource) into arbitrary POJOs, thus facillitating integration of Java EE into third party application frameworks.
I will demonstrate Java EE 6 based development using code examples with some support from the wamblee.org utilities library using a Wicket applicationĀ At a later stage I will also look at how to cleanly integrate OSGI services into applications.