JBoss's Gavin King has published the early draft review of JSR-299, Web Beans in the Java Community Process (JCP). According to the JSR, "The goal of this work is to enable EJB 3.0 components to be used as JSF managed beans, unifying the two component models and enabling a considerable simplification to the programming model for web-based applications in Java." It continues:
Web Beans provides a unifying component model for Java EE by defining:
- A programming model for stateful, contextual components, where metadata may be defined using either annotations or XML deployment descriptors. This component model is compatible with both EJB 3.0 and JavaBeans.
- A sophisticated, typesafe dependency injection mechanism.
- Integration with the Unified Expression Language (EL).
- Support for method and component lifecycle interceptors.
- An event notification model.
- A facility for overriding API implementations at deployment time.
- A facility for configuring components via XML.
- An extensible context model.
- A web conversation context in addition to the three standard web contexts defined by the Java Servlet specification.
- Conversation-scoped JPA extended persistence context management.
- A deployment and packaging model compatible with existing Java EE standards. Web Beans is compatible with Java EE 5 and above.
In particular, Web Beans allows EJB 3.0 components to be used as JSF managed beans, thus unifying the the component models of EJB and JSF and significantly simplifying the programming model when EJB and JSF are used together.
Comments are due by December 1.