Developing EJB 3.1 Applications

You can use the workbench to develop and test enterprise beans that conform to the distributed component architecture defined in the Sun Microsystems Enterprise JavaBeans (EJB) 3.10 specification.

Using this specification, you can develop beans more simply than in the 2.1 standard. You can annotate your Java source code to provide information that was previously contained in XML deployment descriptors. Using Java™ annotations allows you to create EJBs and Java Persistence Architecture (JPA) beans quickly and easily from “plain old Java objects (POJOs). For EJBs, these can be created without implementing EnterpriseBean interfaces.

This product supports the Enterprise JavaBeans 2.1 and 3.0 specification levels. All of the EJB tools in the product are accessible from the Java EE perspective in the workbench. You can create session beans (stateful or stateless) or message-driven beans, by simply specifying the component defining annotation in your POJO. Additional configuration for your bean can be done by specifying additional annotations in the Java class. The Java editor provides validation, content assistance and QuickFixes for your EJB 3.0 annotations, as well as support for refactoring beans. For richer assistance with the EJB 3.0 annotations, you can use the Annotations view to add or delete annotations, and to modify the attribute values of annotations. Deployment descriptors for your EJB 3.0 modules are optional, but can be created for additional configuration.

New in EJB 3.1 (JSR 318)

Java EE 5 streamlines EJB development in the following ways:

For further additional information on EJB 3.0, see the official specification: JSR 220: Enterprise JavaBeans™ 3.0