Find JSRs
Submit this Search


Ad Banner
 
 
 
 

Summary  |  Proposal  |  Detail (Summary & Proposal)
JSRs: Java Specification Requests
JSR 299: Contexts and Dependency Injection for the JavaTM EE platform

Stage Access Start Finish
Final Release Download page 10 Dec, 2009  
Final Approval Ballot View results 17 Nov, 2009 30 Nov, 2009
Proposed Final Draft 2 Download page 16 Nov, 2009  
Proposed Final Draft Download page 01 Jul, 2009  
Public Review Ballot View results 03 Feb, 2009 09 Feb, 2009
Public Review Download page 05 Nov, 2008 09 Feb, 2009
Early Draft Review Download page 17 Oct, 2007 01 Dec, 2007
Expert Group Formation   06 Jun, 2006 30 Nov, 2006
JSR Review Ballot View results 23 May, 2006 05 Jun, 2006
Status: Final
JCP version in use: 2.7
Java Specification Participation Agreement version in use: 2.0


Description:
The purpose of this specification is to unify the JSF managed bean component model with the EJB component model, resulting in a significantly simplified programming model for web-based applications.

Please direct comments on this JSR to the Spec Lead(s)
Team

Specification Leads
  Gavin King Red Hat
Expert Group
  Adobe Systems Inc. Apache Software Foundation Caucho Technology, Inc
  Drees, Matt ERDOGDU, Gurkan Ericsson AB
  Hookom, Jacob J IBM Ihns, Oliver
  Kennard, Richard Lundgren, Conny Maki, Chris
  Mann, Kito D. Marinschek, Martin Oracle
  Pramati Technologies Red Hat Sun Microsystems, Inc.
  Sybase Tiwari, Shashank TmaxSoft, Inc.
  Youngstrom, Michael

List of compatible implementations

 
Updates to the Original JSR

The following information has been updated from the original proposal.

2009.12.10:
The name of the JSR was changed to "Contexts and Dependency Injection for the Java EE platform".

2009.06.30:

2.18 Please provide a description of the business terms for the Specification, RI and TCK that will apply when this JSR is final.

The Specification will be licensed for evaluation and implementation.

The RI and TCK will be licensed via the ASL 2.0 license.

2009.01.26:
The name of the JSR was changed from "Web Beans" to "Contexts and Dependency Injection for Java".


Original Java Specification Request (JSR)

Identification | Request | Contributions | Additional Information

Section 1. Identification

Submitting Member: JBoss

Name of Contact Person: Gavin King

E-Mail Address: gavin.king@jboss.com

Telephone Number: +1 404 822 8349

Fax Number: +1 404 948 1496


Specification Lead: Gavin King

E-Mail Address: gavin.king@jboss.com

Telephone Number: +1 404 822 8349

Fax Number: +1 404 948 1496


Initial Expert Group Membership:

Supporting this JSR:

Borland Software Corp
Google
JBoss, Inc
Oracle Corporation
Sun Microsystems, Inc
Sybase, Inc



Section 2: Request

2.1 Please describe the proposed Specification:

The EJB architecture is a component architecture for the development and deployment of component-based business applications. In particular,EJB provides a programming model for components that access transactional resources. Applications written using the Enterprise JavaBeans architecture are scalable, transactional, and multi-user secure. The EJB 3.0 release significantly enhanced and simplified the EJB programming model, making heavy use of Java annotations.

Even so, the EJB component model still has some limitations:

    * EJB components are not aware of the web-tier request, session and application contexts and do not have access to state associated with those contexts. Nor may the lifecycle of a stateful EJB component be scoped to a web-tier context.

    * EJB components are not in general suitable for use in the presentation tier.

    JavaServer Faces is a web-tier presentation framework that provides, among other facilities, a component model for graphical user interface components, a "managed bean" component model for application logic, and an event-driven interaction model that binds the two component models. The managed bean component model is a contextual model where components are bound to one of the three web tier contexts and may hold contextual state.

    * JSF provides no integrated facilities for accessing transactional resources from managed bean components.

    * The managed bean component model provides no component-level or method-level security.

    * The context model provided by the servlet specification - and leveraged by JSF - is insufficiently rich for use in complex applications in an enterprise environment.

    * The JSF component model is not consistent with Java EE component registry (JNDI), dependency injection, packaging and deployment standards.

    * The current release of JSF has not yet embraced Java annotations.

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.

In particular, this work will provide a programming model suitable for rapid development of simple data-driven applications without sacrificing the full power of the Java EE 5 platform. This is a domain where Java EE has been perceived as overly complex.

To enable use of this simplified programming model beyond the realm of simple internet-facing web applications, this work will define an enhanced context model that provides first-class constructs for modelling user interactions. The enhanced context model will dramatically simplify the creation of complex stateful applications with sophisticated user interactions.

Aspects that should be considered in this work include, but are not limited to, the following:

    * Definition of additional capabilities to be used with the EJB component model, allowing EJB beans to act as JSF managed beans in a JavaServer Faces application. This is in principle possible without requiring any changes to the EJB or JSF specifications. However, where appropriate, new features could be incorporated into the EJB specification or JSF specification at the discretion of the respective expert groups.

    * Definition of a unified annotation-based facility for manipulating contextual variables in a stateful, contextual, component-base architecture. * Definition of an enhanced context model including conversational and business process contexts.

    * Definition of an extension point allowing integration of business process management engines with the contextual component model.

    * Integration of Java Persistence API extended persistence contexts with the enhanced context model.

    * Collaboration with the JSF and Common Annotations for the Java Platform expert groups on the definition of Java annotation based metadata for JSF.

    * Ensure that components written to conform to this specification may be executed in the context of a Web Services invocation.

    * Ensure that the component model can be used with JSR-227 databinding.

The goal of the Expert Group will be to investigate these issues and identify and pursue other directions that allow a simplification of the overall programming model, while leaving issues relevant only to the EJB specification or only to the JSF specification to the respective Expert Groups.

2.2 What is the target Java platform? (i.e., desktop, server, personal, embedded, card, etc.)

Java Enterprise Edition

2.3 The Executive Committees would like to ensure JSR submitters think about how their proposed technology relates to all of the Java platform editions. Please provide details here for which platform editions are being targeted by this JSR, and how this JSR has considered the relationship with the other platform editions.

The target platform is Java EE 5. The work will track new functionality in Java EE 6 as it develops.

2.4 Should this JSR be voted on by both Executive Committees?

No

2.5 What need of the Java community will be addressed by the proposed specification?

This work will address the need of the Java community for a simplified programming model for web-based applications. In particular, this model is suited to rapid development of simple data driven applications and widens the potential market for Java EE technology.

2.6 Why isn't this need met by existing specifications?

Existing specifications evolved independently and currently lack the deep level of integration that is proposed here. This lack of integration results in many usability issues.

2.7 Please give a short description of the underlying technology or technologies:

The goals of this work may in principle be met by implementing a framework on top of existing technology in Java EE 5.

2.8 Is there a proposed package name for the API Specification? (i.e., javapi.something, org.something, etc.)

Not known at this time.

2.9 Does the proposed specification have any dependencies on specific operating systems, CPUs, or I/O devices that you know of?

No

2.10 Are there any security issues that cannot be addressed by the current security model?

No

2.11 Are there any internationalization or localization issues?

The relevant internationalization problems are solved by the JSF specification.

2.12 Are there any existing specifications that might be rendered obsolete, deprecated, or in need of revision as a result of this work?

No. This specification builds upon existing APIs.

2.13 Please describe the anticipated schedule for the development of this specification.

The following dates are preliminary:

Expert Group Formation: July 2006
Early Draft Review: March 2007
Public Review: September 2007
Final Release: April 2008

2.14 Please describe the anticipated working model for the Expert Group working on developing this specification.

The primary means of communication will be email, with conference calls and face-to-face meetings scheduled as needed.

2.15 It is important to the success of the community and each JSR that the work of the Expert Group be handled in a manner which provides the community and the public with insight into the work the Expert Group is doing, and the decisions that the Expert Group has made. The Executive Committees would like to ensure Spec Leads understand the value of this transparency and ask that each JSR have an operating plan in place for how their JSR will address the involvement of the community and the public. Please provide your plan here, and refer to the Spec Lead Guide for a more detailed description and a set of example questions you may wish to answer in your plan.

The Expert Group will publish early drafts at convenient points during the development of the specification, and solicit feedback from the community.

2.16 Please describe how the RI and TCK will de delivered, i.e. as part of a profile or platform edition, or stand-alone, or both. Include version information for the profile or platform in your answer.

JBoss will deliver a Reference Implementation (RI) and Technology Compatibility Kit (TCK) compatible with Java EE 5 and license compatible with Java EE licensing as part of the final specification.

2.17 Please state the rationale if previous versions are available stand-alone and you are now proposing in 2.13 to only deliver RI and TCK as part of a profile or platform edition (See sections 1.1.5 and 1.1.6 of the JCP 2 document).

N/A

2.18 Please provide a description of the business terms for the Specification, RI and TCK that will apply when this JSR is final.

The license will be a free-of-charge open source license compatible with Java EE licensing.





Section 3: Contributions

3.1 Please list any existing documents, specifications, or implementations that describe the technology. Please include links to the documents if they are publicly available.

EJB 3.0, http://jcp.org/en/jsr/detail?id=220
JSF 1.2, http://jcp.org/en/jsr/detail?id=252
JBoss Seam, http://jboss.com/products/seam
Struts Shale, http://struts.apache.org/struts-shale
Oracle ADF, http://www.oracle.com/technology/products/adf/index.html

3.2 Explanation of how these items might be used as a starting point for the work.

This work builds upon the existing EJB and JSF specifications. The JBoss Seam framework demonstrates a possible solution to some of the listed issues, and shows that a solution is possible in principle. Struts Shale and Oracle ADF embody some of the same ideas.



Section 4: Additional Information (Optional)

4.1 This section contains any additional information that the submitting Member wishes to include in the JSR.