Contexts and Dependency Injection for Java EE

Get Started. It's Free
or sign up with your email address
Rocket clouds
Contexts and Dependency Injection for Java EE by Mind Map: Contexts and Dependency Injection for Java EE

1. implementations

1.1. Weld (reference impl.)

1.1.1. Oracle GlassFish Server 3.x JBoss Enterprise Application Platform 6 JBoss Application Server 7.x

1.2. OpenWebBeans

1.2.1. Apache TomEE Apache Geronimo 3.x IBM WebSphere Application Server 8.0 and 8.5 IBM WebSphere Application Server Liberty Profile 8.5 SiwPas

1.3. CanDI

1.3.1. Caucho Resin 4.0.17

2. evolution

2.1. EE6

2.1.1. JSR 299: cdi 1.0 (web beans)

2.1.2. JSR 330: Dependency Injection for Java

2.2. EE7

2.2.1. JSR 346: cdi 1.1

2.3. ? EE8

2.3.1. JSR 000346: cdi 1.2 just released

3. usage (cdi 1.0)

3.1. maven dependency

3.2. beans.xml must be present (even if it is empty) in the deployment unit

3.2.1. in WEB-INF for .war

3.2.2. in META-INF for .jar

4. availability

4.1. Web profile (since EE6)

4.2. Servlet containers (like Tomcat 6.X and Jetty 6.X) can also be extended with Weld or OpenWebBeans by dropping the proper jars in webapp's /WEB-INF/lib and doing the proper configuration in web.xml.

4.3. standalone Java SE

5. features

5.1. Basic dependency injection

5.1.1. @Inject

5.1.2. @Qualifier, @Stereotype

5.1.3. @Alternative, Instance,

5.1.4. @All, @Any, @Default

5.2. Component naming

5.2.1. @Named

5.3. Context management

5.3.1. @Dependent, @RequestScoped, @SessionScoped, @ConversationScoped, @ApplicationScoped, @Scope

5.4. Custom Object Factories

5.4.1. • @Produces, @Disposes, InjectionPoint

5.5. Lightweight Events

5.5.1. Event, @Observes

5.6. Interceptors

5.6.1. @Interceptor, @InterceptorBinding, @AroundInvoke, InvocationContext

5.7. Decorators

5.7.1. @Decorator, @Delegate

6. charecteristics

6.1. Next-generation dependency injection for Java EE

6.2. Best ideas from Seam, Guice and Spring

6.3. Loose-coupling

6.4. Java-centric type-safety, annotations, expressiveness and ease-of-use

6.5. Makes Java EE much more flexible, testable, pluggable and extensible

7. IDE suport

7.1. Eclipse

7.1.1. JBoss Tools

7.1.1.1. Provides excellent support for CDI (which Eclipse currently does not)

7.1.1.2. CDI wizards, validation, quick-fix, auto-completion, navigation

7.1.2. Glassfish plugin

7.1.2.1. Weak support

7.2. Netbeans

7.3. IntelliJ

8. cdi bean

9. Please follow the link (arrow) to my simple GitHub code examples for this topic.