lundi 13 janvier 2014

JEE 6 Container

JEE 6 Container

As discussed previously, the concept of DI was widely adopted and also realized by JCP. As a result, in
JEE 6, the technology stack (EJB 3.1, JPA 2.1, JSR-299, JSR-330, etc.) was mostly revamped to adopt DI
and simplify the development of JEE applications. So, when you are developing an application for
JEE 6–compliant application servers, you can use standard DI techniques across all layers. At the time of
writing, popular JEE 6–compliant application servers include JBoss AS 7, Oracle Glassfish 3.1, and
WebSphere 8.

PicoContainer

PicoContainer

PicoContainer (www.picocontainer.org) is an exceptionally small (around 300KB) DI container that
allows you to use DI for your application without introducing any dependencies other than
PicoContainer. Because PicoContainer is nothing more than a DI container, you may find that as your
application grows, you need to introduce another framework, such as Spring, in which case you would
have been better off using Spring from the start. However, if all you need is a tiny DI container, then
PicoContainer is a good choice,

Google Guice

Google Guice

Another popular DI framework is Google Guice (http://code.google.com/p/google-guice). Led by the
search engine giant Google, Guice is a lightweight framework that focuses on providing DI for
application configuration management. It was also the reference implementation of the JSR-330
specification (“Dependency Injection for Java”).
JBoss Seam Framework :


Founded by Gavin King (the creator of the Hibernate ORM library), the Seam Framework
(www.seamframework.org) is another full-blown DI-based framework; it contains layers from web
application front-end (JSF), the business logic layer (EJB 3), and JPA for persistence. As you can see, the
main difference between Seam and Spring is that the Seam framework is built entirely on JEE standards.
JBoss also contributes the ideas in the Seam framework back to the JCP and becomes JSR-299 (“Contexts
and Dependency Injection for the Java EE Platform”).