[jboss-dev-forums] [Design of POJO Server] - Java EE inter-module accessibility for Web Beans

pete.muir@jboss.org do-not-reply at jboss.com
Mon Jun 29 10:28:00 EDT 2009


JSR-299 requires that [3]:

anonymous wrote : Beans packaged in a certain Java EE module or library are available for injection, lookup and EL resolution to classes and 
  | JSP/JSF pages packaged in some other Java EE module or library if and only if the first module or library is required to be 
  | accessible to the other module or library by the Java EE platform specification. 
  | 
  | Note that, in some containers, a bean class might be accessible to some other class even when this is not required by the 
  | Java EE platform specification. For the purposes of this specification, a class is not considered accessible to another class 
  | unless accessibility is explicitly required by the Java EE platform specification. 

For Web Beans, we will require that the Java EE container provides the deployment structure information. My current proposal is to require the container to provide a BeanDeploymentArchive[1] instance per module/library. The BeanDeploymentArchive contains a list of other BeanDeploymentArchive which it can access, as well as a list o the classes and deployment descriptor it contains. In the case of an EJB module, the container additionally exposes the EJB metadata for that module [2].

The Web Beans bootstrap would require the root BeanDeploymentArchive as an input. In the case of a EAR, the root BeanDeploymentArchive would return an emtpy class iteration, and null for the beans.xml URL, and accessible modules/libraries as normal.

I'm interested in feedback both on the API design (and how well it matches EE class accessibility rules in other's opinions), and on how to implement this in JBoss AS.

[1]https://svn.jboss.org/repos/webbeans/ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/BeanDeploymentArchive.java
[2]https://svn.jboss.org/repos/webbeans/ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/EJBModule.java
[3]http://in.relation.to/Bloggers/JSR299ProposedFinalDraftSubmitted#attachment1, Section 5.1

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4240775#4240775

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4240775



More information about the jboss-dev-forums mailing list